An unknown server-side error occurred while processing the command. Original error: Unable to launch WebDriverAgent because of xcodebuild failure: "xcodebuild failed with code 65 xcodebuild error message: 2019-04-24 19:47:08.231 xcodebuild[16191:4823753] Error Domain=IDETestApplcationDependencyMapperErrorDomain Code=2 "The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read." UserInfo={NSLocalizedFailureReason=The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”., NSURL=file:///Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app/, NSFilePath=/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app, NSLocalizedDescription=The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read.} 2019-04-24 19:47:08.232 xcodebuild[16191:4823753] Error Domain=IDETestOperationsObserverErrorDomain Code=4 "Failed to install or launch the test runner" UserInfo={NSLocalizedRecoverySuggestion=If you believe this error represents a bug, please attach the result bundle at /Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Logs/Test/Test-WebDriverAgentRunner-2019.04.24_19-47-07-+0800.xcresult, NSLocalizedDescription=Failed to install or launch the test runner, NSUnderlyingError=0x7fb65434dcf0 {Error Domain=IDETestApplcationDependencyMapperErrorDomain Code=2 "The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read." UserInfo={NSLocalizedFailureReason=The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”., NSURL=file:///Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app/, NSFilePath=/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app, NSLocalizedDescription=The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read.}}} Testing failed: 'CocoaAsyncSocket/CocoaAsyncSocket.h' file not found The test runner encountered an error (Failed to install or launch the test runner. (Underlying error: The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read. The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”.)) ** TEST EXECUTE FAILED ** Testing started on 'iPhone X'".

[MJSONWP] 2019-04-24 19:47:08.231 xcodebuild[16191:4823753] Error Domain=IDETestApplcationDependencyMapperErrorDomain Code=2 "The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read." UserInfo={NSLocalizedFailureReason=The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”., NSURL=file:///Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app/, NSFilePath=/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app, NSLocalizedDescription=The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read.}
[MJSONWP] 2019-04-24 19:47:08.232 xcodebuild[16191:4823753] Error Domain=IDETestOperationsObserverErrorDomain Code=4 "Failed to install or launch the test runner" UserInfo={NSLocalizedRecoverySuggestion=If you believe this error represents a bug, please attach the result bundle at /Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Logs/Test/Test-WebDriverAgentRunner-2019.04.24_19-47-07-+0800.xcresult, NSLocalizedDescription=Failed to install or launch the test runner, NSUnderlyingError=0x7fb65434dcf0 {Error Domain=IDETestApplcationDependencyMapperErrorDomain Code=2 "The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read." UserInfo={NSLocalizedFailureReason=The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”., NSURL=file:///Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app/, NSFilePath=/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app, NSLocalizedDescription=The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read.}}}
[MJSONWP] Testing failed:
[MJSONWP] 'CocoaAsyncSocket/CocoaAsyncSocket.h' file not found
[MJSONWP] The test runner encountered an error (Failed to install or launch the test runner. (Underlying error: The bundle identifier for WebDriverAgentRunner-Runner.app couldn’t be read. The application may be damaged or incomplete: “/Users/network/Library/Developer/Xcode/DerivedData/WebDriverAgent-dikkwtrisltbeobjmfvpthwwekvs/Build/Products/Debug-iphonesimulator/WebDriverAgentRunner-Runner.app”.))
[MJSONWP] ** TEST EXECUTE FAILED **
[MJSONWP] Testing started on 'iPhone X'".
[MJSONWP] at quitAndUninstall (/Applications/Appium.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/lib/driver.js:488:13)
[HTTP] <-- POST /wd/hub/session 500 55342 ms - 3108
[HTTP]
[HTTP] --> DELETE /wd/hub/session
[HTTP] {}
[HTTP] No route found. Setting content type to 'text/plain'
[HTTP] <-- DELETE /wd/hub/session 404 1 ms - 57
[HTTP]


↙↙↙阅读原文可查看相关链接,并与作者交流