<div dir="ltr">Thanks Andrew. This is good stuff and makes a lot of sense to know where we stand and to set some targets when we're in a chunk of the code to leave it better than we found it, especially if we're updating for a feature. </div><br><div class="gmail_quote"><div dir="ltr">On Thu, Nov 26, 2015 at 2:24 AM Andrew Wilkins <<a href="mailto:andrew.wilkins@canonical.com">andrew.wilkins@canonical.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">It's been on my TODO list for a long time to set up regular coverage testing for Juju. I still haven't done it, but I've written a script that gets us a step closer:<div>    <a href="https://gist.github.com/axw/457a402b4dfb4e4267f9" target="_blank">https://gist.github.com/axw/457a402b4dfb4e4267f9</a></div><div><br></div><div>If you have gocov (go get <a href="http://github.com/axw/gocov/gocov" target="_blank">github.com/axw/gocov/gocov</a>), then you can run the above and you'll get a gocov profile sent to stdout after all the tests run. The usage for the script is, for example:</div><div>    juju-coverage.bash <a href="http://github.com/juju/juju/." target="_blank">github.com/juju/juju/.</a>..<br></div><div><br></div><div>You can pipe the output back into a gocov command, e.g.</div><div>    juju-coverage.bash <a href="http://github.com/juju/juju/." target="_blank">github.com/juju/juju/.</a>.. | gocov report<br></div><div><br></div><div>More likely, though, we would want to convert to Cobertura format using <a href="https://github.com/AlekSi/gocov-xml" target="_blank">https://github.com/AlekSi/gocov-xml</a>, and then use the Jenkins plugin to render the output. Alternatively we could use <a href="https://github.com/mattn/goveralls" target="_blank">https://github.com/mattn/goveralls</a> to send the results to <a href="http://coveralls.io" target="_blank">coveralls.io</a>.</div><div><br></div><div>It would be nice to get this done so we know where testing is lacking. Maybe at Oakland?</div><div><br></div><div>Cheers,</div><div>Andrew</div></div>
--<br>
Juju-dev mailing list<br>
<a href="mailto:Juju-dev@lists.ubuntu.com" target="_blank">Juju-dev@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju-dev" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailman/listinfo/juju-dev</a><br>
</blockquote></div>