view coverage.sh @ 553:bd8c4d4688d5

use conforming format for snappy compression This finally enables reading/writing compressed leveldbs written by the original implementation. Before this, the incompatible compression format prevented this. Fixes #17
author Lewin Bormann <lbo@spheniscida.de>
date Thu, 30 Jun 2022 21:09:05 -0700
parents 6887e24fd83f
children
line wrap: on
line source

#!/bin/bash
set -x

KCOV=kcov
KCOV_OPTS="--exclude-pattern=/.cargo,/glibc,/usr/lib,/usr/include"
KCOV_OUT="./kcov-out/"

export RUSTFLAGS="-C link-dead-code"

TEST_BIN=$(cargo test 2>&1 >/dev/null | awk '/^     Running target\/debug\/deps\// { print $2 }')

echo $TEST_BIN
${KCOV} ${KCOV_OPTS} ${KCOV_OUT} ${TEST_BIN} && xdg-open ${KCOV_OUT}/index.html