mirror of
https://github.com/actions/actions-runner-controller.git
synced 2025-12-14 22:24:45 +00:00
Fix runners to do their best to gracefully stop on pod eviction (#1759)
Ref #1535 Ref #1581 Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com>
This commit is contained in:
36
test/startup/test.sh
Executable file
36
test/startup/test.sh
Executable file
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
source assets/logging.sh
|
||||
|
||||
for unittest in ./should*; do
|
||||
log "**********************************"
|
||||
log " UNIT TEST: ${unittest}"
|
||||
log "**********************************"
|
||||
log ""
|
||||
cd ${unittest}
|
||||
./test.sh
|
||||
ret_code=$?
|
||||
cd ..
|
||||
|
||||
log ""
|
||||
log ""
|
||||
if [ "${ret_code}" = "0" ]; then
|
||||
success "Completed: unit test ${unittest}"
|
||||
else
|
||||
error "Completed: unit test ${unittest} with errors"
|
||||
failed="true"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "${failed:-}" ]; then
|
||||
error ""
|
||||
error "*************************************"
|
||||
error "All unit tests completed, with errors"
|
||||
error "*************************************"
|
||||
exit 1
|
||||
else
|
||||
success ""
|
||||
success "***************************************"
|
||||
success "All unit tests completed with no errors"
|
||||
success "***************************************"
|
||||
fi
|
||||
Reference in New Issue
Block a user