-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Executable monitor update to use a thread to run and monitor the output. Parent task then monitors the join time of the child to monitor if it has timed out. Also adding a different check for if the exe exits, but we haven't found a desired success message * Use echo groups to clean output * Adding some tests to the executable monitor, making it so that if it finds the success message or the exit status it works * Swapping from exit status to exit code * Adding default timeout tests, remove failure on no timeout provided test * Run the happy path test once where it passes with the success line, and once where it passes with the timeout * Changes to the action.yml to remake log file optional ---------
- Loading branch information
Showing
6 changed files
with
487 additions
and
141 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*.out | ||
logDir/ | ||
demo_run_logs/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
Test the case where exit status code and success line are given but hit timeout | ||
python3 executable-monitor.py --log-dir . --success-exit-status 0 --success-line "Sleeping for 27 seconds" --retry-attempts 2 --timeout-seconds 10 --exe-path test.out ; echo $? | ||
|
||
# Run a test where we find the success line but the exe does not exit, ensure exit status is 0 | ||
#python3 executable-monitor.py --log-dir . --success-line "Sleeping for 27 seconds" --retry-attempts 2 --timeout-seconds 10 --exe-path test.out; echo $? | ||
|
||
Test a run where the thread will timeout while waiting for the success message, ensure exit status is 1 | ||
# python3 executable-monitor.py --log-dir . --success-line "Sleeping for 27 seconds" --retry-attempts 2 --timeout-seconds 2 --exe-path test.out; echo $? |
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
Oops, something went wrong.