Testing application on Xcode13 beta 5 fails to launch iOS15 simulators

Hello.

I'm having problems testing my app using Xcode13 beta 5 and iOS15 simulators.

When I try to run the tests of a target that needs a host application on a iOS 15 simulator I get the following crash before the test starts:

Thread 1: EXC_BAD_ACCESS (code=EXC_I386_GPFLT)

dyld_sim`getpid:
  0x10ccd7765 <+0>: pushq %rbp
  0x10ccd7766 <+1>: movq  %rsp, %rbp
  0x10ccd7769 <+4>: leaq  0x38950(%rip), %rax    ; gSyscallHelpers
  0x10ccd7770 <+11>: movq  (%rax), %rax
-> 0x10ccd7773 <+14>: cmpq  $0x5, (%rax)
  0x10ccd7777 <+18>: jb   0x10ccd7780        ; <+27>
  0x10ccd7779 <+20>: popq  %rbp
  0x10ccd777a <+21>: jmpq  *0x128(%rax)
  0x10ccd7780 <+27>: callq 0x10ccd7fef        ; findHostFunctions
  0x10ccd7785 <+32>: popq  %rbp
  0x10ccd7786 <+33>: jmpq  *0x38fa4(%rip)      ; proc_getpid

If I run the tests with Fastlane, on the console it shows:

▸ Testing failed:
▸ 	MYAPPTests:
▸ 		MYAPP (66354) encountered an error (Test runner never began executing tests after launching.)
▸ ** TEST EXECUTE FAILED **

On targets that does not need a host application it works well.

And if try to run the same target with host application but on a iOS 14 simulator, it works fine.

So the problem seems to be the iOS15 simulator.

Any tips? Thank you!

What Mac and macOS versions are you running the simulator on?

Accepted Answer

Hello. Good news. This issue seems to be fixed on Xcode13 RC 1.

Hello. Just want to say that this issue is NOT fixed on Xcode13 RC 1 nor Xcode13 Release. My mistake.

When I said that it was fixed, I did not realize that I was using a simulator running iOS14, sorry.

It fails with iOS15 simulators.

The same issue. Temporarily specified destination in fastlane scan command to 'platform=iOS Simulator,name=iPhone 12,OS=14.5'

Has anyone encountered a fix for this? we had to run our tests on iOS 14 as a workaround, but it's no good.

The issue doesn't seem to be resolved in Xcode 13.1 RC... Anyone found a solution yet? This issue keeps us from upgrading everything to Xcode 13...

Any news for this issue? I have 3 projects and only having this exact issue on 1 of the projects. Can't figure out what is different. Any other info would be great....is there a way to remove the accepted answer?

The solution for us was to remove the pod Texture more info about issue here - https://github.com/TextureGroup/Texture/issues/2029

So look at your dependencies that might have UIView hooks.

Also happening in Xcode 13.1 running in iOS 15.0 simulators, 20% of our tests failed because of this, reported in FB9794773

Looking at the xcresult logs I found this info but not too helpful:

18:02:04.554 Xcode[72384:6322690] 8D4BD7E8-6674-461B-9079-C12C459B0530: Launching app with identifier: com.some.identifier and options: {
.... // OMITED BECAUSE IT'S TOO LARGE
}
18:02:04.723 Xcode[72384:6322689] 8D4BD7E8-6674-461B-9079-C12C459B0530: Launched app with identifier: com.some.identifier (pid = 80902)
18:02:04.724 Xcode[72384:6322689] 📱<DVTiPhoneSimulator (0x14be19470), iPhone 8 Plus, unknown class, 15.0 (19A339), 8D4BD7E8-6674-461B-9079-C12C459B0530> tracking pid 80902
18:02:04.724 Xcode[72384:6322689] 📱<DVTiPhoneSimulator (0x14be19470), iPhone 8 Plus, unknown class, 15.0 (19A339), 8D4BD7E8-6674-461B-9079-C12C459B0530> checking to see if pid 80902 is valid: kill(pid, 0) = 0 (YES, it's still running)
18:02:04.732 Xcode[72384:5738902] Test process runnable PID is 80902.
18:02:04.732 Xcode[72384:6322621] XCTHTestOperationStateMachine: Transitioning from state Initial to AcquiredPID
18:07:34.729 Xcode[72384:6327051] XCTHTestOperationStateMachine: Startup timer fired; the test runner has not made forward progress for 300.00 seconds
18:07:34.730 Xcode[72384:6327051] XCTHTestOperationStateMachine: Transitioning from state AcquiredPID to BootstrappingHang
18:07:34.730 Xcode[72384:5738902] Acquiring spindump to help determine why test runner got stuck after launching
18:07:39.927 Xcode[72384:5738902] Retrieved spindump data of 3394 bytes
18:07:39.927 Xcode[72384:5738902] Test operation failure: Test runner never began executing tests after launching
18:07:39.934 Xcode[72384:5738902] _finishWithError:Error Domain=XCTHTestOperationCoordinatorErrorDomain Code=14 "Test runner never began executing tests after launching" UserInfo={NSLocalizedDescription=Test runner never began executing tests after launching}

Maybe there is a way to increment the startup timeout (300s) from Test Runner?

Looks good on xcode 13.2

i use Xcode13.2.1, the problem still  exists

same here, had it on 13.2.1

We are still facing the issue on 13.2.1

  • It worked well when installed the simulator of iOS 14.5 but not with 15.2 (Xcode 13)
  • We had Texture even after removing it's not working.

Any solutions for this?

Hello!

If you are still seeing issues in this area, please file a report on Feedback Assistant so we can help you diagnose the issue.

https://feedbackassistant.apple.com/

Testing application on Xcode13 beta 5 fails to launch iOS15 simulators
 
 
Q