gpt4 book ai didi

ios - XCTest 在 travis 尝试运行测试时崩溃

转载 作者:行者123 更新时间:2023-11-29 10:43:01 26 4
gpt4 key购买 nike

我正在尝试设置 travis 来运行我现有的测试。我正在使用 XCTest,并且可以使用 xctool test 在本地成功运行测试。我有 .xctool-args 文件设置和所有需要的配置。在 Travis 上构建完成但 xctest 崩溃。这是崩溃日志

Test did not run: the test bundle stopped running or crashed before the test suite started.
CRASH REPORT: xctest_2014-05-07-064505_Traviss-Mac-32.crash
Process: xctest [1517]
Path: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk/Developer/usr/bin/xctest
Identifier: xctest
Version: 13.2
Code Type: X86 (Native)
Parent Process: sim [1514]
Responsible: xctest [1517]
User ID: 501
Date/Time: 2014-05-07 06:44:57.294 -0700
OS Version: Mac OS X 10.9.2 (13C64)
Report Version: 11
Anonymous UUID: AFA30136-CB6D-6480-DAA2-9E74869E8355
Crashed Thread: 8 Dispatch queue: com.apple.root.default-priority
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x00000000704f535a
VM Regions Near 0x704f535a:
__LINKEDIT 000000002010d000-0000000020113000 [ 24K] r--/rwx SM=COW /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk/Developer/Library/Frameworks/XCTest.framework/XCTest
-->
__TEXT 000000008fef2000-000000008ff25000 [ 204K] r-x/rwx SM=COW /usr/lib/dyld
Application Specific Information:
objc_msgSend() selector name: reachabilityRef
iPhone Simulator (external launch) , iPhone OS 7.1 (unknown/11D167)

最佳答案

这与其说是答案,不如说是解决方法。使用 xctool 进行的测试在本地工作,但在 travis 上使用 xctool 似乎有问题。我通过使用 xcodebuild 而不是使用 xctool 的默认测试脚本解决了我的问题。

language: objective-c
script:
- xcodebuild -scheme SchemeName -destination 'platform=iOS Simulator,name=iPhone Retina
(4-inch),OS=7.1' test

关于ios - XCTest 在 travis 尝试运行测试时崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23544411/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com