Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: support xccov JSON format #377

Open
eelco opened this issue Nov 22, 2018 · 3 comments
Open

Feature Request: support xccov JSON format #377

eelco opened this issue Nov 22, 2018 · 3 comments

Comments

@eelco
Copy link

eelco commented Nov 22, 2018

For a while now (since Xcode 9.3) Apple ships a tool for code coverage. (Run it with xcrun xccov).

It can read the coverage files generated by Xcode and translate them into JSON.

It would be great if the test reporter could support those JSON files, as it would save a bunch of dependencies for getting Objective-C / Swift coverage into Code Climate.

@wfleming
Copy link
Contributor

Good idea! Our team probably won't be able to incorporate this into our own planning in the near-term, so I've added the "help wanted" label here. This would be great to see as a PR if anyone has time.

@andresilveirah
Copy link

Sorry for the digging this issue out of the grave but has this perhaps been addressed on #399 ? And could anyone point me to the doc on how to use it?

@manicmaniac
Copy link

I also cannot find the document but it worked as I expected.

$ xcodebuild test -resultBundlePath result_bundle.xcresult
$ xcrun xccov view --report --json result_bundle.xcresult > coverage.json
$ cc-test-reporter format-coverage -t xccov coverage.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants