citrun

watch C/C++ source code execute
Log | Files | Refs | LICENSE

commit 165152617670764cef91530a087a9a484f024873
parent 6c58e4cdcc62a4e03be92d4828c74db3440e241c
Author: Kyle Milz <kyle@0x30.net>
Date:   Wed, 10 Aug 2016 00:42:26 -0600

t: delete process_citrun_log

Diffstat:
Mt/inst_correct.t | 47+++++++++++++++++++++--------------------------
Mt/inst_dowhile.t | 42++++++++++++++++++++----------------------
Mt/inst_for.t | 41+++++++++++++++++++----------------------
Mt/inst_if.t | 41+++++++++++++++++++----------------------
Mt/inst_return.t | 41+++++++++++++++++++----------------------
Mt/inst_switch.t | 39++++++++++++++++++---------------------
Mt/inst_while.t | 41+++++++++++++++++++----------------------
7 files changed, 135 insertions(+), 157 deletions(-)

diff --git a/t/inst_correct.t b/t/inst_correct.t @@ -31,37 +31,32 @@ main(int argc, char *argv[]) } EOF -cat <<EOF > citrun.log.good +cat <<EOF > check.good +Checking ..done -citrun-inst v0.0 () called as ''. -Resource directory is '' -PATH='' -Command line is ''. -Found source file ''. -Object arg = 1, compile arg = 0 -Link detected, adding '' to command line. -Added clangtool argument ''. -Instrumentation of '' finished: - 25 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 5 Function definitions - 3 If statements - 6 Return statement values - 4 Call expressions - 198 Total statements -Modified source written successfully. -Instrumentation successful. -Running native compiler on modified source code. -Forked ''. -'' exited 0. -Restored ''. +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Forked compilers + 1 Instrument successes + 1 Application link commands + +Totals: + 25 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 5 Function definitions + 3 If statements + 6 Return statement values + 4 Call expressions + 198 Total statements EOF cc -o fib fib.c +citrun-check > check.out -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 2 citrun.log diff" +diff -u check.good check.out && echo "ok 2 citrun.log diff" export CITRUN_SOCKET= ./fib diff --git a/t/inst_dowhile.t b/t/inst_dowhile.t @@ -26,30 +26,28 @@ main(int argc, char *argv[]) } EOF -cat <<EOF > citrun.log.good - -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 9 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 1 Function definitions - 1 Do while loops - 1 Return statement values - 11 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +cat <<EOF > check.good +Checking ..done + +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 9 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 1 Function definitions + 1 Do while loops + 1 Return statement values + 11 Total statements EOF citrun-inst -c while.c +cat citrun.log +citrun-check > check.out diff -u while.c.inst_good while.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff" diff --git a/t/inst_for.t b/t/inst_for.t @@ -30,30 +30,27 @@ main(int argc, char *argv[]) } EOF -cat <<EOF > citrun.log.good - -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 11 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 4 Function definitions - 1 For loops - 1 Return statement values - 155 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +cat <<EOF > check.good +Checking ..done + +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 11 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 4 Function definitions + 1 For loops + 1 Return statement values + 155 Total statements EOF citrun-inst -c for.c +citrun-check > check.out diff -u for.c.inst_good for.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff" diff --git a/t/inst_if.t b/t/inst_if.t @@ -44,31 +44,28 @@ main(int argc, char *argv[]) } EOF -cat <<EOF > citrun.log.good +cat <<EOF > check.good +Checking ..done -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 18 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 4 Function definitions - 3 If statements - 4 Return statement values - 2 Call expressions - 173 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 18 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 4 Function definitions + 3 If statements + 4 Return statement values + 2 Call expressions + 173 Total statements EOF citrun-inst -c if.c +citrun-check > check.out diff -u if.c.inst_good if.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff" diff --git a/t/inst_return.t b/t/inst_return.t @@ -32,30 +32,27 @@ int main(void) {citrun_start();++_citrun_lines[4]; } EOF -cat <<EOF > citrun.log.good - -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 12 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 2 Function definitions - 4 Return statement values - 1 Call expressions - 14 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +cat <<EOF > check.good +Checking ..done + +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 12 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 2 Function definitions + 4 Return statement values + 1 Call expressions + 14 Total statements EOF citrun-inst -c return.c +citrun-check > check.out diff -u return.c.inst_good return.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff" diff --git a/t/inst_switch.t b/t/inst_switch.t @@ -38,30 +38,27 @@ main(void) } EOF -cat <<EOF > citrun.log.good +cat <<EOF > check.good +Checking ..done -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 15 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 1 Function definitions - 1 Switch statements - 1 Return statement values - 14 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 15 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 1 Function definitions + 1 Switch statements + 1 Return statement values + 14 Total statements EOF citrun-inst -c switch.c +citrun-check > check.out diff -u switch.c.inst_good switch.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff" diff --git a/t/inst_while.t b/t/inst_while.t @@ -28,30 +28,27 @@ main(int argc, char *argv[]) } EOF -cat <<EOF > citrun.log.good - -citrun-inst v0.0 () called as ''. -Resource directory is '' -Command line is ''. -Found source file ''. -Object arg = 0, compile arg = 1 -Added clangtool argument ''. -Instrumentation of '' finished: - 10 Lines of source code - 32 Lines of instrumentation header - 1 Functions called '' - 1 Function definitions - 2 While loops - 1 Return statement values - 18 Total statements -Writing modified source to ''. -Modified source written successfully. -Instrumentation successful. +cat <<EOF > check.good +Checking ..done + +Summary: + 1 Log files found + 1 Source files input + 1 Calls to the instrumentation tool + 1 Instrument successes + +Totals: + 10 Lines of source code + 32 Lines of instrumentation header + 1 Functions called 'main' + 1 Function definitions + 2 While loops + 1 Return statement values + 18 Total statements EOF citrun-inst -c while.c +citrun-check > check.out diff -u while.c.inst_good while.c.citrun && echo "ok 2 - instrumented source diff" - -process_citrun_log -diff -u citrun.log.good citrun.log.proc && echo "ok 3 - citrun.log diff" +diff -u check.good check.out && echo "ok 3 - citrun.log diff"