]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
drd/tests/pth_barrier[23]: Filter output such that only the error count is kept
authorBart Van Assche <bvanassche@acm.org>
Fri, 29 Jul 2011 07:22:29 +0000 (07:22 +0000)
committerBart Van Assche <bvanassche@acm.org>
Fri, 29 Jul 2011 07:22:29 +0000 (07:22 +0000)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11940

drd/tests/Makefile.am
drd/tests/filter_error_count [new file with mode: 0755]
drd/tests/pth_barrier2.stderr.exp
drd/tests/pth_barrier2.vgtest
drd/tests/pth_barrier3.stderr.exp
drd/tests/pth_barrier3.vgtest

index 191316bb8afd3dacd343658839b3d491a7d732a0..e85a67167c7ad9550920aea4dbb4212128b5c369 100644 (file)
@@ -3,6 +3,7 @@ include $(top_srcdir)/Makefile.tool-tests.am
 
 dist_noinst_SCRIPTS =              \
        compare_error_count_with    \
+       filter_error_count          \
        filter_error_summary        \
        filter_stderr               \
        filter_stderr_and_thread_no \
diff --git a/drd/tests/filter_error_count b/drd/tests/filter_error_count
new file mode 100755 (executable)
index 0000000..89dc2b4
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+# Filter the error output of Valgrind such that only the line with the error
+# summary is kept. Bart Van Assche, February 26, 2008.
+
+sed -n \
+  -e 's/^.*\(ERROR SUMMARY.*\) ([^()]*)$/\1/' \
+  -e 's/^\(ERROR SUMMARY: [0-9]* errors\).*$/\1/' \
+  -e '/ERROR SUMMARY/p'
index bb25d5288aaf86f45816aea15f932659a9893eb2..4a04a26189929dd1f38d375d82dc1d54ad578556 100644 (file)
@@ -1 +1 @@
-ERROR SUMMARY: 32 errors from 1 contexts
+ERROR SUMMARY: 32 errors
index 1fe94089a69bfda2d6f288b9e333f5767934169d..56a897b8390ff6bc5aeb3d0961820a9ae6fb7733 100644 (file)
@@ -1,4 +1,4 @@
 prereq: test -e pth_barrier && ./supported_libpthread
 prog: pth_barrier
 args: 2 32 1
-stderr_filter: filter_error_summary
+stderr_filter: filter_error_count
index 6c5b8a3576b92306399ccf2d63a1db83ed3bb6ba..d3c07b9c253085e47d302b2e49a99686bb2db57c 100644 (file)
@@ -1 +1 @@
-ERROR SUMMARY: 31 errors from 1 contexts
+ERROR SUMMARY: 31 errors
index c17edb19a07a449c8f6633d594946418be0d7cbb..8c24a03c625e54fd1be0d38e7b41c8f14830bc47 100644 (file)
@@ -1,4 +1,4 @@
 prereq: test -e pth_barrier && ./supported_libpthread
 prog: pth_barrier
 args: 32 1 1
-stderr_filter: filter_error_summary
+stderr_filter: filter_error_count