From 28c7ef509e56e5fc1619afcdcf2fc3243bf2da36 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sun, 12 Nov 2006 08:22:46 +0100 Subject: Avoid false-positive when testing via valgrind. * tests/mv/atomic: Grep strace output for a more specific pattern than just "unlink", since that got a false positive when testing under valgrind: unlink("/tmp/valgrind_proc_9657_cmdline_A51E9991") = 0 * tests/mv/Makefile.am (TESTS_ENVIRONMENT): Define EGREP. --- tests/mv/Makefile.am | 1 + tests/mv/atomic | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'tests/mv') diff --git a/tests/mv/Makefile.am b/tests/mv/Makefile.am index 927bac89b..57581cd88 100644 --- a/tests/mv/Makefile.am +++ b/tests/mv/Makefile.am @@ -46,5 +46,6 @@ TESTS = \ EXTRA_DIST = $(TESTS) vfat TESTS_ENVIRONMENT = \ PERL="$(PERL)" \ + EGREP="$(EGREP)" \ PATH="$(VG_PATH_PREFIX)`pwd`/../../src$(PATH_SEPARATOR)$$PATH" \ PROG=mv diff --git a/tests/mv/atomic b/tests/mv/atomic index bb761bdc4..1fa07360f 100755 --- a/tests/mv/atomic +++ b/tests/mv/atomic @@ -58,7 +58,7 @@ fi fail=0 strace -qe unlink mv -T s1 s2 > out 2>&1 || fail=1 -grep unlink out && fail=1 +$EGREP 'unlink.*"s1"' out && fail=1 # Ensure that the source, s1, is gone. ls -dl s1 > /dev/null 2>&1 && fail=1 -- cgit v1.2.3-70-g09d2