File: do-tests.sh

package info (click to toggle)
grandorgue 3.17.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 37,928 kB
  • sloc: xml: 63,791; cpp: 53,876; sh: 601; makefile: 8
file content (28 lines) | stat: -rwxr-xr-x 465 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/bash

# $1 - optional - [test | coverage | gcovr] - If nothing is provided,
# run all the tests steps.

set -e

STEP=$1

TEST_SCRIPT="ctest -T test --verbose"
COVERAGE_SCRIPT="ctest -T coverage"
GCOVR_SCRIPT="gcovr -e 'submodules/*|usr/*'"

case $STEP in
    "test") 
        $TEST_SCRIPT
    ;;
    "coverage")
        $COVERAGE_SCRIPT
    ;;
    "gcovr")
        $GCOVR_SCRIPT
    ;;
    "")
        $TEST_SCRIPT ; $COVERAGE_SCRIPT ; $GCOVR_SCRIPT
esac;