-2

I do a simple swift project using XCode7.3. Everything is ok, UI & Unit test run properly too. However, when I wanna see coverage data, I can not run unit test anymore

ld: framework not found Pods_MapView
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Would you please give me a clue?

P/S: I hostes my project at https://github.com/rickyngk/map-view-demo

enter image description here

Ricky
  • 569
  • 4
  • 16

2 Answers2

0

Try adding your target to your Podfile: e.g.:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.1'
use_frameworks!
target 'MapView' do
    pod 'GoogleMaps'
end

target 'MapViewTests' do
    pod 'GoogleMaps'
end

target 'MapViewUITests' do
    pod 'GoogleMaps'
end
Keaton Burleson
  • 498
  • 3
  • 16
  • It does not work properly. After updating podfile & run pods update, I got another issue http://stackoverflow.com/questions/26287103/cocoapods-warning-cocoapods-did-not-set-the-base-configuration-of-your-project After fixing that issue, I got another error `/Users/duynk/Library/Developer/Xcode/DerivedData/MapView-aewsozizpzwxylewdysdxgtztozo/Build/Intermediates/MapView.build/Debug-iphonesimulator/MapView.build/Script-3CDB27006D5C13F5155CF92B.sh: line 2: /Users/duynk/projects/map-view-demo/iOS/Pods/Target Support Files/Pods/Pods-frameworks.sh: No such file or directory` – Ricky Apr 11 '16 at 18:38
0

I've found my own answer:

  1. Remove Pods & Podfile.lock
  2. Follow this https://stackoverflow.com/a/28116102/1960061
  3. Done

enter image description here

Community
  • 1
  • 1
Ricky
  • 569
  • 4
  • 16