-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Abort the job on the main thread if the test suite fails #32
Merged
TheRustifyer
merged 24 commits into
zerodaycode:main
from
gbm25:27-abort-the-job-on-the-main-thread-if-the-test-suite-fails
Dec 16, 2023
Merged
Abort the job on the main thread if the test suite fails #32
TheRustifyer
merged 24 commits into
zerodaycode:main
from
gbm25:27-abort-the-job-on-the-main-thread-if-the-test-suite-fails
Dec 16, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
More tests and another suite case have been added to test the different RUN_TESTS options.
Bugs that prevented compilation have been fixed. ENUM TestRunBehavior names have been changed and relevant documentation has been added.
An output has been added in the FreeTest in case of error and with behavior "ABORT_ALL_ON_FAIL".
Se ha movido y modificado el output de error en caso de error en freetest con el modo 'ABORT_ALL_ON_FAIL'. Se ha añadido output de warning en caso de error en freetest con el modo 'HALT_SUITE_ON_FAIL'.
The code in which the suite tests were processed has been moved to its own function.
In case of an error in the tests an exception is thrown. This exception is thrown at different times depending on the error mode used.
Added output when a test fail on a suite on HALT_SUITE_ON_FAIL mode. Reformat file.
Fixed a bug on ABORT_ALL_ON_FAIL mode when a test fails in a suite. Added output.
Using Default value on RUN_TESTS(). Added comments.
The exception is eliminated in favor of exit(1) since error output is already returned.
The test suite documentation has been updated, adding information on test execution modes. Updated the example of use with more tests, to be able to see more clearly how the modes work in the result images.
The old example image of the output of the previous example code in the README is removed, as it does not reflect the actual code written and the modes are not reflected.
Due to an oversight this information had not been added in one of the previous commits.
TheRustifyer
approved these changes
Dec 16, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Update to Test Suite Fail-Fast Behavior
Summary
This PR implements key enhancements to the fail-fast behavior of our custom test suite, as discussed in the #27 issue threads. The focus is on refining the test execution strategy and preparing for future enhancements.
Key Changes
Fail-Fast Behavior Enhancement: The
RUN_TESTS
function has been updated to support a new parameter for fail-fast configuration, allowing users to specify their preferred test execution strategy. The function now operates in three modes, governed by theTestRunBehavior
enum:CONTINUE_ON_ERROR
: Continues executing tests after failures.HALT_SUITE_ON_FAIL
: Halts the current test suite on failure and proceeds to the next.ABORT_ALL_ON_FAIL
(Default Mode): Aborts all tests immediately upon any failure.Future Enhancements Acknowledged: While the immediate focus is on enhancing the fail-fast behavior, we acknowledge the postponed feature of controlling behavior via command line. Future enhancements, such as output grouping and color styling, are also noted for consideration in subsequent updates.
Conclusion
These updates make our test suite more adaptable and aligned with testing practices. The default mode
ABORT_ALL_ON_FAIL
ensures immediate attention to critical failures, enhancing the development and debugging process.