【发布时间】:2020-11-04 08:56:33
【问题描述】:
当我尝试运行 detox test 时,模拟器似乎没有打开并且测试只是超时。
我确认我的设置是正确的,并尝试this 以确保我的模拟器可以从终端启动,并且我的detox 配置中的设备类型是正确的。
我收到的错误如下。
Timeout - Async callback was not invoked within the 300000ms timeout specified by jest.setTimeout.
Error: Timeout - Async callback was not invoked within the 300000ms timeout specified by jest.setTimeout.
和
DetoxRuntimeError: Detox instance has not been initialized
HINT: There was an error on attempt to call detox.init()
DetoxRuntimeError: Aborted detox.init() execution, and now running detox.cleanup()
HINT: Most likely, your test runner is tearing down the suite due to the timeout error
这是我的配置,出于隐私原因删除了应用名称。
"ios.sim.debug": {
"binaryPath": "ios/build/Build/Products/Debug-iphonesimulator/example.app",
"build": "xcodebuild -workspace ios/example.xcworkspace -scheme example -configuration Debug -sdk iphonesimulator -derivedDataPath ios/build",
"type": "ios.simulator",
"device": {
"type": "iPhone 11 Pro"
}
},
如何调试?
【问题讨论】:
标签: react-native react-native-ios detox