Displaying 3 results from an estimated 3 matches for "8a8c7fc".
2018 Aug 01
2
[PATCH nbdkit] tests: Adjust test-fua.sh for correct use .prepare in log filter.
...ly breaks the FUA test.
Fix this by filtering out the additional log message before counting
the instances of the fua=1 flag in this test.
Thanks: Eric Blake.
---
tests/test-fua.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/test-fua.sh b/tests/test-fua.sh
index 8a8c7fc..0329807 100755
--- a/tests/test-fua.sh
+++ b/tests/test-fua.sh
@@ -132,14 +132,14 @@ test $(grep -c 'connection=1 Flush' fua1.log) -lt \
# all earlier parts of the transaction do not have fua
flush1=$(grep -c 'connection=1 Flush' fua2.log || :)
flush2=$(grep -c 'connection=2...
2018 Aug 01
0
Re: [PATCH nbdkit] tests: Adjust test-fua.sh for correct use .prepare in log filter.
...from the log filter.
Adjust the grep of the test output for FUA to not be confused by
those extra lines.
Signed-off-by: Eric Blake <eblake@redhat.com>
---
tests/test-fua.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/test-fua.sh b/tests/test-fua.sh
index 8a8c7fc..22e0fa6 100755
--- a/tests/test-fua.sh
+++ b/tests/test-fua.sh
@@ -132,14 +132,14 @@ test $(grep -c 'connection=1 Flush' fua1.log) -lt \
# all earlier parts of the transaction do not have fua
flush1=$(grep -c 'connection=1 Flush' fua2.log || :)
flush2=$(grep -c 'connectio...
2018 Aug 01
1
[PATCH nbdkit] tests: Cancel trap in cleanup function to avoid recursive traps.
...est-cow.sh
+++ b/tests/test-cow.sh
@@ -62,6 +62,8 @@ pid="$(cat cow.pid)"
cleanup ()
{
status=$?
+ trap '' INT QUIT TERM EXIT ERR
+ echo $0: cleanup: exit code $status
kill $pid
rm -f $files
diff --git a/tests/test-fua.sh b/tests/test-fua.sh
index 0ec9ef0..8a8c7fc 100755
--- a/tests/test-fua.sh
+++ b/tests/test-fua.sh
@@ -56,6 +56,8 @@ pid1= pid2= pid3= pid4=
cleanup ()
{
status=$?
+ trap '' INT QUIT TERM EXIT ERR
+ echo $0: cleanup: exit code $status
test "$pid1" && kill $pid1
test "$pid2" &&a...