gpt4 book ai didi

ios - 通过命令行运行单元测试 - Swift Project with cocoaPods

转载 作者:搜寻专家 更新时间:2023-10-31 08:33:26 25 4
gpt4 key购买 nike

我正在尝试使用以下命令从我的项目运行单元测试:

xcodebuild test -scheme 'WaveIt' -destination 'platform=iOS Simulator,name=iPhone 6,OS=8.4'

但是我得到了这个:

ld: library not found for -lSocketRocket clang: error: linker command failed with exit code 1 (use -v to see invocation)

Testing failed: Linker command failed with exit code 1 (use -v to see invocation) ** TEST FAILED **

The following build commands failed: Ld DerivedData/WaveIt/Build/Products/Debug-iphonesimulator/WaveIt.app/WaveIt normal x86_64 (1 failure)

我的项目包括带有 cocoaPods 的库:

  • '套接字火箭'
  • “谷歌/分析”

和 Alamofire(git 子模块)

谁能告诉我这是什么问题?

问候

最佳答案

您需要在 xcodebuild 中指定您的工作空间。

xcodebuild test -workspace 'WaveIt.workspace' -scheme 'WaveIt' -destination 'platform=iOS Simulator,name=iPhone 6,OS=8.4'

关于ios - 通过命令行运行单元测试 - Swift Project with cocoaPods,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32236418/

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