#1689: fix set -e masking test failures in Makefile#1785
Conversation
17acba9 to
087c19e
Compare
|
@yegor256 plz review |
| img=$$(cat target/docker-image.txt) | ||
| docker run --rm --entrypoint '/bin/bash' "$${img}" -c 'bundle exec judges test --disable live --lib /action/lib /action/judges' | ||
| echo "$$?" > target/test.exit | ||
| img=$$(cat target/docker-image.txt); \ |
There was a problem hiding this comment.
@VasilevNStas why do we need ; \? it's ONESHELL, should work without this
|
Fixed — removed |
|
Both CI failures are pre-existing and unrelated to this PR:
|
3c7de98 to
f4442fa
Compare
Closes #1689
Fix
set -emasking test failures inMakefile. Thetestandentrytargets usedecho "$$?" > target/*.exitafter the command, butset -ecauses the shell to exit beforeechoruns if the command fails (nonzero exit). Now uses|| rc=$$?to capture the exit code without triggering the errexit trap.Changes:
testtarget: save docker exit code via|| rc=$$?patternentrytarget: same pattern for action test script