now e2e tests read the amount of ft_calloc_calls from the successful execution
and iterates through possible trap values + 2 (just in case). i.e. if there are 31 ft_calloc_if calls in during this mock's execution, it will call valgrind ./minishell --trap 0 --command MOCK_0, valgrind ./minishell --trap 1 --command MOCK_0, ..., valgrind ./minishell --trap 33 --command MOCK_0. in every run a memory allocation error happens, and the shell is expected to recover from it successfully: to print an error message and to exit gracefully, freeing all memory (and not segfault).
a lot of small fixes introduced throughout the project, since when the iteration was introduced, all these places caused segfaults
to validate: opposite to this validation state, now there's no way to segfault mock_0 execution
to build and run: make fulltest
target change:
valgrind ./minishell --trap 0 --command MOCK_0
,valgrind ./minishell --trap 1 --command MOCK_0
, ...,valgrind ./minishell --trap 33 --command MOCK_0
. in every run a memory allocation error happens, and the shell is expected to recover from it successfully: to print an error message and to exit gracefully, freeing all memory (and not segfault).a lot of small fixes introduced throughout the project, since when the iteration was introduced, all these places caused segfaults
to validate: opposite to this validation state, now there's no way to segfault mock_0 execution