mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Improve integration test diagnostics in an attempt to catch run crashes
This commit is contained in:
@@ -40,7 +40,9 @@ jobs:
|
|||||||
if: failure()
|
if: failure()
|
||||||
with:
|
with:
|
||||||
name: Results
|
name: Results
|
||||||
path: test_output/IntegrationTests.xcresult.zip
|
path: |
|
||||||
|
test_output/IntegrationTests.xcresult.zip
|
||||||
|
test_output/console*
|
||||||
retention-days: 7
|
retention-days: 7
|
||||||
if-no-files-found: ignore
|
if-no-files-found: ignore
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,7 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
"diagnosticCollectionPolicy" : "Always",
|
||||||
"environmentVariableEntries" : [
|
"environmentVariableEntries" : [
|
||||||
{
|
{
|
||||||
"key" : "INTEGRATION_TESTS_HOST",
|
"key" : "INTEGRATION_TESTS_HOST",
|
||||||
|
|||||||
@@ -32,6 +32,10 @@ struct IntegrationTests: AsyncParsableCommand {
|
|||||||
} catch {
|
} catch {
|
||||||
testsFailed = true
|
testsFailed = true
|
||||||
logger.error("\n❌ Integration tests failed.\n")
|
logger.error("\n❌ Integration tests failed.\n")
|
||||||
|
|
||||||
|
// Preserve the app's logs alongside the results so that they can be uploaded as artifacts.
|
||||||
|
logger.info("🗂️ Collecting log files…")
|
||||||
|
_ = try? await CI.run(.path("/bin/zsh"), ["-cu", "cp /Users/Shared/console* \(CI.testOutputDirectory)"])
|
||||||
}
|
}
|
||||||
|
|
||||||
// Validate logs only when tests passed — log files won't be meaningful otherwise
|
// Validate logs only when tests passed — log files won't be meaningful otherwise
|
||||||
|
|||||||
Reference in New Issue
Block a user