Skip to content

armgit / peel

Public Imported from GitHub
0

Uninstall Mac apps with every file they leave behind, and see why each belongs. Free up space, fine-tune macOS, and set up Terminal.

Write the Checks workflow's test output to a file

Țugui Dragoș9639e5d011ed
diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml
index 2c2bf4c2..8a7a7bc5 100644
--- a/.github/workflows/checks.yml
+++ b/.github/workflows/checks.yml
@@ -40,9 +40,17 @@ jobs:
exit 1
fi
- # The app's targets treat warnings as errors in the project; the package is held to the same here.
+ # The app's targets treat warnings as errors in the project; the package is held to the same here. The tests
+ # write to a file, since a test that writes a line waits for whoever reads it, and the log is read late here.
- name: Test PeelCore
- run: swift test --package-path Packages/PeelCore -Xswiftc -warnings-as-errors
+ run: |
+ log="$RUNNER_TEMP/test.log"
+ if swift test --package-path Packages/PeelCore -Xswiftc -warnings-as-errors > "$log" 2>&1; then
+ grep -E "Test run with" "$log"
+ else
+ cat "$log"
+ exit 1
+ fi
- name: Build the app
run: |