File: quickchick-expectfailure

package info (click to toggle)
coq-quickchick 2.1.1-2
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 2,432 kB
  • sloc: ml: 4,367; ansic: 789; makefile: 388; sh: 27; python: 4; lisp: 2; perl: 2
file content (17 lines) | stat: -rwxr-xr-x 405 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

# Run a QuickChick test executable ($1) with a given mutant ($2) and ensure at
# least one test fails.

set -e

QC_OUT_DIR=qc-out
mkdir -p $QC_OUT_DIR/

LOG_FILE=$QC_OUT_DIR/testlog-${1##*/}-${2##*/}

echo "Mutant $2: Testing..."
QC_MUTANT=$2 $1 > $LOG_FILE
grep -q '^\*\*\* Failed' $LOG_FILE \
  || (echo "Mutant $2: Tests passed, but failure was expected."; exit 1)
echo "Mutant $2: Killed!"