From 9304caeb0696b5f4361a75451c07016a23812b46 Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Wed, 20 Nov 2019 23:10:07 +0100 Subject: [PATCH] tests: Get rid of asynchronous process substitution Under bash, processes substitution is run asynchronously. This means that the messages printed by the process can be mixed with other messages, which causes random tests to fail, because the wvtest protocol lines are corrupted. Now we run all processes synchronously and the test no longer fail randomly. --- tests/server.wv | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/server.wv b/tests/server.wv index 94fab88..72ed352 100755 --- a/tests/server.wv +++ b/tests/server.wv @@ -171,9 +171,9 @@ target_config="\ " EOF WVFAIL novaboot --ssh novaboot-test@localhost <<<"load file < date" -novaboot --ssh novaboot-test@localhost <<<"load file < date" 2>&1 >/dev/null |\ - tee >(WVPASS grep -q -F 'Unknown option: make') \ - >(WVPASS grep -q -F 'Error processing configuration from the server') +stderr=$(novaboot --ssh novaboot-test@localhost <<<"load file < date" 2>&1 >/dev/null) +echo "$stderr" | WVPASS grep -q -F 'Unknown option: make' +echo "$stderr" | WVPASS grep -q -F 'Error processing configuration from the server' WVSTART "Novaboot --ssh remote config fails on unknown arguments" WVPASS sudo_ tee "$SHELLRC" <