Skip to content

Commit b2016c4

Browse files
committed
ci(ui-tests): upload the test logs
The test logs are quite interesting to have, and not only those: In case of a fatal failure, the test directory is valuable information, too. Let's always upload them as build artifacts. For convenience, let's just reuse the `ui-tests/` directory as the place to put all of those files; Technically, we do not need the files in there that are tracked by Git, but practically speaking, it is neat to have them packaged in the same `.zip` file as the test logs and stuff. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 0be3017 commit b2016c4

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

.github/workflows/ui-tests.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,18 @@ jobs:
8383
ui-tests
8484
- name: Run UI tests
8585
id: ui-tests
86+
working-directory: ui-tests
8687
run: |
87-
"${env:RUNNER_TEMP}\ahk\AutoHotKey64.exe" /ErrorStdOut /force ui-tests/ctrl-c.ahk ui-tests\background-hook.ahk "$PWD\bg-hook" 2>&1 | Out-Default
88+
"${env:RUNNER_TEMP}\ahk\AutoHotKey64.exe" /ErrorStdOut /force ui-tests/ctrl-c.ahk background-hook.ahk "$PWD\bg-hook" 2>&1 | Out-Default
8889
if (!$?) { echo "::error::Test failed!" } else { echo "::notice::Test log" }
8990
type bg-hook.log
9091
if ($p.ExitCode -ne 0) { exit 1 }
9192
- name: Show logs, if canceled
9293
if: cancelled()
94+
working-directory: ui-tests
9395
run: type bg-hook.log
96+
- name: Upload test results
97+
if: always()
98+
uses: actions/upload-artifact@v4
99+
with:
100+
name: ui-tests

0 commit comments

Comments
 (0)