Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/swift/16.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios 将Fastlane与CircleCI集成:未找到Cocoapods框架_Ios_Swift_Cocoapods_Circleci_Fastlane - Fatal编程技术网

Ios 将Fastlane与CircleCI集成:未找到Cocoapods框架

Ios 将Fastlane与CircleCI集成:未找到Cocoapods框架,ios,swift,cocoapods,circleci,fastlane,Ios,Swift,Cocoapods,Circleci,Fastlane,我正在尝试为我的iOS应用程序设置CircleCI,我想与Fastlane集成。 我的circle.yml如下所示: machine: xcode: version: 8.3.1 dependencies: pre: - gem install bundler post: - bundle install - bundle exec pod install - bundle exec fastlane test 在完成测试文件的编译之前,建

我正在尝试为我的iOS应用程序设置CircleCI,我想与Fastlane集成。 我的circle.yml如下所示:

machine:
 xcode:
    version: 8.3.1

dependencies:
  pre:
    - gem install bundler

  post:
    - bundle install
    - bundle exec pod install
    - bundle exec fastlane test
在完成测试文件的编译之前,建筑是正常的;它显示了这个错误

[04:39:38]: ▸ Compiling LoginViewControllerSpec.swift
[04:39:38]: ▸ Compiling QuestionSpec.swift
[04:39:38]: ▸ Compiling ItemSpec.swift
[04:39:38]: ▸ Linking myApp-iosTests
[04:39:38]: ▸ ❌  ld: framework not found Pods_Tests_myAppTests
[04:39:38]: ▸ ❌  clang: error: linker command failed with exit code 1 (use -v to see invocation)
这是我使用cocoapods v1.2.1的pod文件

target 'myApp' do
  # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
  use_frameworks!

    pod "PulsingHalo"
    pod 'OpenTok'
    pod 'Alamofire', '4.0'
    pod 'PieCharts'
    pod 'SwiftHEXColors'
    pod 'IQKeyboardManagerSwift'
    pod 'OAuthSwiftAlamofire'
    pod 'AlamofireObjectMapper', '~> 4.0'


  target 'myAppTests' do
    inherit! :search_paths
    # Pods for testing
    pod 'Quick'
        pod 'Nimble'
  end

  target 'myAppUITests' do
    inherit! :search_paths
    # Pods for testing
    pod 'Quick'
    pod 'Nimble'
  end

end
我试了两天都没有成功。我还更改了目标测试中的构建选项

我真的很感激你能给我的任何帮助


谢谢

能否确保podfile中的目标名称与构建阶段中的二进制框架名称匹配

还有一个旁注;bundle exec pod安装没有问题,但我会将pod安装移到fastlane,有一个名为before_all的通道可以在测试通道之前为您安装pod

platform :ios do |options|
  before_all do |lane, options|
   cocoapods // this would replace pod install
  end

这行代码没有意义,应该是Pods\u-myAppTests,你能打开你的工作区,进入每个目标的构建阶段->将二进制文件链接到库来检查.framework是什么吗names@u.gen这里有两个框架:Pods_Tests_myAppTests.framework Pods_myApp_Tests.framework都设置为required我删除了这些框架,因为正如你所说,没有任何意义。我不知道它们是什么时候创建的,但现在它正在工作。非常感谢你!太棒了,请接受我的回答