~ci-train-bot/autopilot/autopilot-legacy-ubuntu-zesty-2535

« back to all changes in this revision

Viewing changes to make_coverage.sh

  • Committer: Thomi Richards
  • Date: 2014-04-30 00:01:38 UTC
  • mfrom: (485.1.4 autopilot-legacy)
  • Revision ID: thomi.richards@canonical.com-20140430000138-ztvk90v11t9pc6rj
Merge in branch that transitions us to autopilot-legacy source package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
usage() {
26
26
        echo "usage: $0 [-h] [-n] [-t]"
27
27
        echo
28
 
        echo "Runs unit tests under both python2 and python 3, gathering coverage data."
 
28
        echo "Runs unit tests under python2, gathering coverage data."
29
29
        echo "By default, will open HTML coverage report in the default browser. If -n"
30
30
        echo "is specified, will re-generate coverage data, but won't open the browser."
31
 
    echo "If -t is specified the HTML coverage report will include the test files."
 
31
        echo "If -t is specified the HTML coverage report will include the test files."
32
32
}
33
33
 
34
34
while getopts ":hnt" o; do
52
52
 
53
53
python -m coverage erase
54
54
python -m coverage run --branch --include "autopilot/*" -m autopilot.run run autopilot.tests.unit
55
 
python3 -m coverage run --append --branch --include "autopilot/*" -m autopilot.run run autopilot.tests.unit
56
55
 
57
56
if [ "$INCLUDE_TEST_FILES" = "yes" ]; then
58
57
    python -m coverage html