5

I use this example to install same pods for different targets

Referenced from this example blog post:

http://natashatherobot.com/cocoapods-installing-same-pod-multiple-targets/

# Podfile

platform :ios, '8.0'
source 'https://github.com/CocoaPods/Specs.git'

link_with ['YourProject']

workspace 'YourProject.xcworkspace'
xcodeproj 'YourProject.xcodeproj'

def shared_pods

    #shared pods

end

def testing_pods

    #shared testing pods

end

target 'YourProject' do
    shared_pods
end

target 'YourProjectTests' do
    shared_pods
    testing_pods
end

target 'YourProjectUITests' do
    shared_pods
    testing_pods
end

But I end up with linking issues in YourProjectUITests target:

Undefined symbols for architecture x86_64:

  "_OBJC_CLASS_$_GAI", referenced from:
      objc-class-ref in Utility.o
  "_OBJC_CLASS_$_GAIDictionaryBuilder", referenced from:
      objc-class-ref in HomeViewController.o

  "_OBJC_CLASS_$_NewRelicAgent", referenced from:
      objc-class-ref in AppDelegate.o
  "_kGAIHitType", referenced from:

Using cocoa pods 0.39.0 & xcode 7.2

I'm going to try to remove the pod.lock & re-install the pods..

When I remove the UITestTarget in the pod config I don't have any conflicts anymore

Wojtek Dmyszewicz
  • 4,188
  • 5
  • 30
  • 42

0 Answers0