Reputation: 31
I want to build the Xcode in command line by enabling 'Generate test coverage files' and 'Instrument program flow' Since i want to do the code coverage from jenkins i want to set the 'Generate test coverage files' and 'Instrument program flow' of XCode to be enabled. I know the GUI option where to set but i want to run from Terminal since from jenkins it will build thorough the command line
xcodebuild -workspace ../x.xcodeproj/project.xcworkspce -scheme y then what should i give in the above command to enable the 'Generate test coverage files' and 'Instrument program flow'
Upvotes: 1
Views: 568
Reputation: 3854
Add .xcconfig file to your project with following content
GCC_INSTRUMENT_PROGRAM_FLOW_ARCS = YES
GCC_GENERATE_TEST_COVERAGE_FILES = YES
and run xcodebuild with -xcconfig flag passing it path to your config file
Upvotes: 2