blob: 068213a3d29935765c81015af24904dd85978d64 [file] [log] [blame]
Craig Tiller934baa32015-01-12 18:19:45 -08001#!/bin/bash
2
3set -ex
4
5out=`realpath ${1:-coverage}`
6
7root=`realpath $(dirname $0)/../..`
8tmp=`mktemp`
9cd $root
Craig Tiller45bc6002015-01-27 09:15:38 -080010tools/run_tests/run_tests.py -c gcov -l c c++
Craig Tiller934baa32015-01-12 18:19:45 -080011lcov --capture --directory . --output-file $tmp
12genhtml $tmp --output-directory $out
13rm $tmp
14if which xdg-open > /dev/null
15then
16 xdg-open file://$out/index.html
17fi
18