iOS UI test failing due to Application <bundle> is not running


#1

Hello,
My ci build was running fine until last 2 days it started failing and the errors I see is not very clear. It looks like the unit tests passed but the UI tests failed because the simulator wasn’t running. I prewarmed my simulator already in the config, namely xcrun instruments -w "iPhone 8 (11.4) [" || sleep 15. Here’s the failed build. Did the simulator got quit after the unit tests ran? How can I keep it until the end of the build? Thanks

▸ Compiling CommonHelper.swift
▸ Compiling AppTests.swift
▸ Compiling OrgMdl.swift
▸ Compiling PrivilegesMdl.swift
▸ Linking AppTests
▸ Running script '[CP] Embed Pods Frameworks'
▸ Running script '[CP] Copy Pods Resources'
▸ Touching AppTests.xctest
▸ Signing /Users/distiller/Library/Developer/Xcode/DerivedData/App-diuokpaexnzpqocorfohjjxfqhns/Build/Products/Debug-iphonesimulator/AppTests.xctest
All tests
Test Suite AppTests.xctest started
ClaimCodeTest
✓ testGetClaimCode (0.009 seconds)
✓ testMatch (0.001 seconds)
◷ testPerformanceGetXYZ measured (0.000 seconds)
✓ testPerformanceGetXYZ (0.385 seconds)
◷ testPerformanceMatchXYZ measured (0.000 seconds)
✓ testPerformanceMatchXYZ (0.256 seconds)
AppTests
✓ testExample (0.002 seconds)
◷ testPerformanceExample measured (0.000 seconds)
✓ testPerformanceExample (0.254 seconds)
PrivilegesMdlTests
✓ testMdl (0.005 seconds)
◷ testPerformanceExample measured (0.000 seconds)
✓ testPerformanceExample (0.299 seconds)


	 Executed 8 tests, with 0 failures (0 unexpected) in 1.210 (1.219) seconds

All tests
Test Suite AppUITests.xctest started
SnapshotTests
✗ testAppflow, Application com.bundle.name is not running


AppUITests.SnapshotTests
testAppflow, Application com.bundle.name is not running
SnapshotHelperXcode8.swift:261


	 Executed 1 test, with 1 failure (0 unexpected) in 35.807 (35.811) seconds

Failing tests:
SnapshotTests.testAppflow()
** TEST FAILED **
[01:20:00]: Exit status: 65
+--------------------+---+
|      Test Results      |
+--------------------+---+
| Number of tests    | 9 |
| Number of failures | 1 |
+--------------------+---+