簡體   English   中英

在Xcode 5.0中運行單元測試時出錯

[英]Error when running unit tests in Xcode 5.0

當我嘗試在xcode 5.0中創建單元測試文件時,出現以下錯誤:

The test bundle at /.../Tests.octest could not be loaded because it is built for a different architecture than the currently-running test rig (which is running as x86_64).

我該怎么辦?

您可能正在嘗試在“iPhone Retina(4英寸64位)”模擬器中運行測試。

切換到“iPhone Retina(4英寸)”模擬器,事情應該工作正常

您可以嘗試關閉Xcode並刪除

〜/資源庫/開發/ Xcode中/ DerivedData / ModuleCache

我在使用XCTest框架時遇到了類似的問題。 最后,我刪除了所有測試,並通過創建新的測試目標將其添加回來。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM