blob: ab934b37976fff921a00f1e4f99ab3322577a861 (
plain) (
blame)
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
29
30
31
32
33
|
#!/bin/bash
set -e
if [[ ! ( -e xmonad.cabal && -e dist/hpc/tix/properties/properties.tix ) ]]; then
echo "run in the same dir as xmonad.cabal after having run
cabal configure --enable-tests --enable-library-coverage; cabal test
"
exit 1
fi
propsExclude=$(find tests/Properties -name '*.hs' \
| sed -e 's_/_._g' -e 's_.hs$__' -e 's_^tests._--exclude=_' )
hpcFlags="
--hpcdir=dist/hpc/mix/
dist/hpc/tix/properties/properties.tix
"
if [[ ! (-e dist/hpc/mix/Main.mix) ]]; then
mv dist/hpc/mix/properties/* dist/hpc/mix/
mv dist/hpc/mix/xmonad-*/xmonad-*/* dist/hpc/mix/xmonad-*/
fi
hpc markup --destdir=dist/hpc $hpcFlags > /dev/null
echo "see dist/hpc/hpc_index.html
"
hpc report $hpcFlags
|