Libraries not found when using CocoaPods with iOS logic tests

前端 未结 14 1384
没有蜡笔的小新
没有蜡笔的小新 2020-11-29 15:41

I am trying to write some iOS logic tests against classes in my project that use functionality from some of the libraries in my podspec. I am using the standard unit test bu

14条回答
  •  情话喂你
    2020-11-29 16:27

    Next syntax gives best result for me (tested under cocoapod v.1.2.1):

    https://github.com/CocoaPods/CocoaPods/issues/4626#issuecomment-210402349

     target 'App' do
        pod 'GoogleAnalytics' , '~> 3.0'
        pod 'GoogleTagManager' , '~> 3.0'
    
         pod 'SDWebImage', '~>3.7'
         platform :ios, '8.0'
         use_frameworks!
    
         target 'App Unit Tests' do
             inherit! :search_paths
         end
     end
    

    Without this I have warnings while test run about duplicate symbols.

    After this warnings were disappear.

提交回复
热议问题