0

I am managing project dependencies using cocoa pods. I added GHUnit target into my project and it is working fine.

I have a problem in importing pods (cocoa pods) files into GHUnit target.

For example, AFNetwork is added to my pod, how can I import AFJSONRequestOperation header into a GHUnit test class? (I conldn'd find the files when trying to add them manually in build phase).

Clement Prem
  • 3,112
  • 2
  • 23
  • 43
  • 1
    Here is a tutorial showing how to properly use AFNetworking, GHUnit, and CocoaPods http://nscookbook.com/2013/03/recipe-18-unit-testing-with-ghunit-cocoapods/ – MTurner Apr 22 '13 at 23:01

1 Answers1

1

Take a look at my answer here. The idea is that you have to link your pods with both targets of your application with link_with which is documented here.

Example:

link_with ['MainTarget', 'TestTarget']

This will link all your pods with both so you can use the other pods in your tests.

Community
  • 1
  • 1
Keith Smiley
  • 61,481
  • 12
  • 97
  • 110