Ios 无法使用xcodebuild执行单元测试用例。它随机失效 这回答了你的问题吗?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你解决过这个问题吗?是的,对我来说,这是因为发射时间。我的应用程序的启动时间

Ios 无法使用xcodebuild执行单元测试用例。它随机失效 这回答了你的问题吗?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你解决过这个问题吗?是的,对我来说,这是因为发射时间。我的应用程序的启动时间,ios,swift,xcode,macos,unit-testing,Ios,Swift,Xcode,Macos,Unit Testing,无法使用xcodebuild执行单元测试用例。它随机失效 这回答了你的问题吗?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你解决过这个问题吗?是的,对我来说,这是因为发射时间。我的应用程序的启动时间相当长。因此,您可以为测试用例创建MockAppDelegate,也可以将代码从AppDelegate移动到其他位置。这是否回答了您的问题?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你

无法使用xcodebuild执行单元测试用例。它随机失效
这回答了你的问题吗?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你解决过这个问题吗?是的,对我来说,这是因为发射时间。我的应用程序的启动时间相当长。因此,您可以为测试用例创建MockAppDelegate,也可以将代码从AppDelegate移动到其他位置。这是否回答了您的问题?不,不是每次都这样。如果我运行命令五次,就会出现两次此错误。它显示了3次success@iKushal你解决过这个问题吗?是的,对我来说,这是因为发射时间。我的应用程序的启动时间相当长。因此,您可以为测试用例创建MockAppDelegate,也可以将代码从AppDelegate移动到其他位置。
I am running unit tests from terminal with below commands. Sometime they executed well, some time not. I am using Xcode 11. Can someone help me 



xcodebuild \
-workspace MyApp.xcworkspace \
-scheme MyScheme \
-configuration Debug \
-sdk iphonesimulator \
-derivedDataPath "BuildBinaryForTest" \
-destination platform=iOS\ Simulator,name=iPhone\ 11 \
clean test | tee xcodebuild.log | xcpretty

I am getting below error

UnitTest:
    MyApp.app (19571) encountered an error (Early unexpected exit, operation never finished bootstrapping - no restart will be attempted. (Underlying error: Test runner exited before starting test execution.))