Skip to content

Commit 5fed68a

Browse files
committed
ci(dockerized): do show the result of failing tests again
The quality of tests/test suites does not show as much when there are no breakages as in the amount of time required after bugs trigger test failures before the bugs can be identified, analyzed and resolved. As such, it is an unfortunate side effect of 2a21098 (github: adapt containerized jobs to be rootless, 2025-01-10) that the output of failed test cases, which was shown before that change directly in the build logs, is now no longer shown at all. The reason is a side effect of trying to run the build and the tests with permissions other than the `root` user, but without providing the prerequisite permissions to signal what tests failed and whose output hence needs to be included in the logs. The way this signaling works is for the workflow to write into special-purpose files whose path is specific to the current workflow step and which can be accessed via the `$GITHUB_ENV` environment variable. It is this path's parent directory that has no write permission for the `builder` user that was introduced in above-mentioned commit. The solution is simple: make the parent directory of those files world-writable. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 91ec48f commit 5fed68a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,7 @@ jobs:
436436
- run: ci/install-dependencies.sh
437437
- run: useradd builder --create-home
438438
- run: chown -R builder .
439+
- run: chmod o+w "${GITHUB_ENV%/*}" # allow `builder` to set environment variables
439440
- run: sudo --preserve-env --set-home --user=builder ci/run-build-and-tests.sh
440441
- name: print test failures
441442
if: failure() && env.FAILED_TEST_ARTIFACTS != ''

0 commit comments

Comments
 (0)