jonreid / XcodeCoverage

Code coverage for Xcode projects (Objective-C only)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Xcode 5.1 Changes

designatednerd opened this issue · comments

I'm having some issues running ./getcov after switching to Xcode 5.1 (I've replaced any calls to my app name with [App] and its test suite to [AppTests]):

Ellens-MacBook-Pro-2:XcodeCoverage ellenshapiro$ ./getcov ~/Library/Developer/Xcode/DerivedData/[App]-gsolxombszraeughodjqqewnlxgd/Build/Products/Debug-iphonesimulator ~/Desktop/[App]/iOS_SDK/Project/XcodeCoverage ~/Desktop/[App]/iOS_SDK/Project/XcodeCoverage Capturing coverage data from /Users/ellenshapiro/Library/Developer/Xcode/DerivedData/[App]-gsolxombszraeughodjqqewnlxgd/Build/Intermediates/[App].build/Debug-iphonesimulator/[AppTests].build/Objects-normal/i386 gcov: Unknown command line argument '-v'. Try: '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/gcov -help' gcov: Did you mean '-a'? gcov: Not enough positional command line arguments specified! Must specify at least 1 positional arguments: See: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/gcov -help geninfo: Use of uninitialized value $version_string in pattern match (m//) at /Users/ellenshapiro/Desktop/[App]/iOS_SDK/Project/XcodeCoverage/lcov-1.10/bin/geninfo line 1874. geninfo: Use of uninitialized value $gcov_version_string in pattern match (m//) at /Users/ellenshapiro/Desktop/[App]/iOS_SDK/Project/XcodeCoverage/lcov-1.10/bin/geninfo line 3622. geninfo: Use of uninitialized value $gcov_version_string in pattern match (m//) at /Users/ellenshapiro/Desktop/[App]/iOS_SDK/Project/XcodeCoverage/lcov-1.10/bin/geninfo line 3622. Scanning /Users/ellenshapiro/Library/Developer/Xcode/DerivedData/[App]-gsolxombszraeughodjqqewnlxgd/Build/Intermediates/[App].build/Debug-iphonesimulator/[AppTests].build/Objects-normal/i386 for .da files ... geninfo: ERROR: no .da files found in /Users/ellenshapiro/Library/Developer/Xcode/DerivedData/[App]-gsolxombszraeughodjqqewnlxgd/Build/Intermediates/[App].build/Debug-iphonesimulator/[AppTests].build/Objects-normal/i386! Reading tracefile Coverage.info lcov: ERROR: no valid records found in tracefile Coverage.info Reading tracefile Coverage.info lcov: ERROR: no valid records found in tracefile Coverage.info Reading data file Coverage.info genhtml: ERROR: no valid records found in tracefile Coverage.info The file /Users/ellenshapiro/Library/Developer/Xcode/DerivedData/[App]-gsolxombszraeughodjqqewnlxgd/Build/Products/Debug-iphonesimulator/lcov/index.html does not exist.
I was able to find this Stack Overflow post, which appears to have some information like that -v is now deprecated, but it seems from that post like Xcode 5.1 has opened up a rather large can of worms with this change.

Any thoughts on how to make this script play nice with Xcode 5.1?

FYI, commit 6aaccdb fixed this issue for me (although I did have to do a clean of the build folder and rerun my tests to get it to see all the classes). Thanks for the quick turnaround!