Adding this answer, in case it will help somebody else.
While installing pod which will also connect to our test targets. We need to write podfile as follows ,
def shared_pods
specify pods here
end
target 'AppName' do
shared_pods
end
target 'AppNameTests' do
shared_pods
end
Adding the target entry in your Podfile will cause CocoaPods to generate a new set of files the next time you run pod install
. However, before you run that command, you will probably need to set your configurations to None, so that Cocoapods can assign its own configuration. Here's how to do that:
- Go to your project-level target
- For each configuration listed under Configurations, select None for your target, in the drop-down menu under Based on Configuration File.
Once you've edited your Podfile and you nullified your configurations, you're ready to run pod install
on the command line. After the process is completed, check back with your base configuration settings, and note that they have been set to the configuration file that was generated by CocoaPods!
I hope that helps!