3 RUNLTTV
=~
/devel
/lttv
/runlttv
6 echo "$0: $@" >/dev
/stderr
10 echo "Usage: $0 [ -N pattern_name ] [ -n pattern_count ] PATTERN TRACE_PARENT_DIR"
13 if [ ! -x "$RUNLTTV" ]; then
14 echo "$0: $RUNLTTV not executable. Edit \$RUNLTTV to point to your lttv source directory." >/dev
/stderr
18 while getopts ":n:N:" options
; do
20 n
) expected_count
=$OPTARG;;
30 shift $
(($OPTIND - 1))
33 if [ -z "$pattern" ]; then
34 error
"no pattern specified"
40 error
"no trace directory specified"
44 traces
=$
(find "$2" -mindepth 1 -maxdepth 1 -type d
)
46 echo -n "Analyzing trace ($name): "
48 cnt
=$
($RUNLTTV -m text
"$traces" |
grep "$pattern" |
wc -l)
49 if [ -z "$expected_count" ]; then
50 if [ "$cnt" -eq "0" ]; then
52 echo "Did not find at least one instance of this event ($cnt)"
59 if [ "$cnt" -ne "$expected_count" ]; then
61 echo "Expected: $expected_count"
This page took 0.039514 seconds and 4 git commands to generate.