]> granicus.if.org Git - strace/commitdiff
tests: fix match_diff usage
authorDmitry V. Levin <ldv@altlinux.org>
Wed, 26 Aug 2015 22:29:41 +0000 (22:29 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Thu, 27 Aug 2015 00:09:46 +0000 (00:09 +0000)
The first argument of match_diff should be the file with expected
output, the second argument - the file with actual output.

* tests/aio.test: Swap match_diff arguments.
* tests/restart_syscall.test: Likewise.
* tests/seccomp.test: Likewise.
* tests/umovestr2.test: Likewise.

tests/aio.test
tests/restart_syscall.test
tests/seccomp.test
tests/umovestr2.test

index 93428f3f65152a483f2e2fb73967177be798eb24..f61b04ec944de80a823019bb71963b2733fb7928 100755 (executable)
@@ -8,7 +8,7 @@ run_prog > /dev/null
 OUT="$LOG.out"
 syscalls=io_setup,io_submit,io_getevents,io_cancel,io_destroy
 run_strace -a14 -e trace=$syscalls $args > "$OUT"
-match_diff "$LOG" "$OUT"
+match_diff "$OUT" "$LOG"
 rm -f "$OUT"
 
 exit 0
index 1daa31651162be596492314554b3edd71d07daff..0e74b2c9c18188b8b21b8410aba85004fd2a3376 100755 (executable)
@@ -23,7 +23,7 @@ case "$STRACE_ARCH" in
        alpha|mips|or1k|s390|s390x)
                # These architectures use the same register
                # both for syscall number and syscall return code.
-               match_diff "$LOG" "$srcdir/restart_syscall_unknown.expected"
+               match_diff "$srcdir/restart_syscall_unknown.expected" "$LOG"
                ;;
        *) match_diff
                ;;
index 4101cae130c63067f509ad1987bcd6bf51cb04ed..0d17221742353842bc8c10cf06ef811d2b24a306 100755 (executable)
@@ -8,7 +8,7 @@ OUT="$LOG.out"
 
 run_prog > /dev/null
 run_strace -veprctl $args > "$OUT"
-match_diff "$LOG" "$OUT"
+match_diff "$OUT" "$LOG"
 
 rm -f "$OUT"
 
index 2e9fee44a77f8d5b704f1e34331454a01b5de7e8..7f00d5fb09ab5bb138de9ddf4649335400fe8c45 100755 (executable)
@@ -11,7 +11,7 @@ run_prog > /dev/null
 run_strace -veexecve -s262144 $args > "$EXP"
 check_prog sed
 sed 1d < "$LOG" > "$OUT"
-match_diff "$OUT" "$EXP"
+match_diff "$EXP" "$OUT"
 
 rm -f "$EXP" "$OUT"