简体   繁体   中英

Xcode failed to run tests

When running unit tests in Xcode I get the following console output:

Failed to run tests: Timeout out trying to establish connection to IDE.test

Why don't my tests run, and how can I resolve this issue?

I had to go to Xcode > Preferences > Locations and change back Command Line Tools to the correct version of Xcode. I had previously changed this value to do something else and forgot to change it back.

In my case it seems XCTest is waiting for some kind of expectation that never fulfilled:

 <XCTWaiter: 0x1c4204a80, state: XCTWaiterStateFailed> reporting timed out failure with Transport for IDE session acquired

I guess it's related to Xcode 10 beta.Anyway, restart everything solved the problem.

  • Clean Project
  • Delete test host app
  • Restart computer
  • Restart iPhone

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM