1

I have unit tests in xcode 5.1, ios7.1, when I run them via the test command within xcode I can see gcda and gcdo files generated in the appropriate place. When I invoke the test command via the command line I only get gcdo files. It must be something to do with the __gcov_flush method that needs to be called to generate the files (I put logs in the flush method I see it in the gui logs but not the terminal logs). I used help from these SO questions

I have also followed the usual advice and set

Generate Test Coverage Files: YES
Instrument Program Flow: YES

At a project level.

My command:

xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -configuration Debug -sdk $IPHONESIMULATOR_VERSION ONLY_ACTIVE_ARCH=YES  clean build test

Is there a reason why it would work within xcode but not via the command line?

Community
  • 1
  • 1
teddy777
  • 661
  • 8
  • 20

0 Answers0