Message ID | 20240125110122.16257-1-frank@lichtenheld.com |
---|---|
State | Accepted |
Headers | show |
Series | [Openvpn-devel,v7] forked-test-driver: Show test output always | expand |
Tested this in various build environments, including Ubuntu/MinGW, and GHA, and things still work & test "as before". Combined with the previous commit, we get useful (for me) "I can see what make check is doing all the time" behaviour back. I'm still not convinced that this is a better way forward than just using the old test-driver and possibly tweaking Makefiles a bit, but "this does work for me", and automake upstream seems to think it's the way to go... thanks, Frank, for doing the actual work :-) Your patch has been applied to the master branch. commit e2ff9161e1b1b3e8c83bf01e3c488e0601834c0c Author: Frank Lichtenheld Date: Thu Jan 25 12:01:22 2024 +0100 forked-test-driver: Show test output always Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com> Acked-by: Arne Schwabe <arne-openvpn@rfc2549.org> Message-Id: <20240125110122.16257-1-frank@lichtenheld.com> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg28133.html Signed-off-by: Gert Doering <gert@greenie.muc.de> -- kind regards, Gert Doering
diff --git a/forked-test-driver b/forked-test-driver index be73b80..6971dfb 100755 --- a/forked-test-driver +++ b/forked-test-driver @@ -108,9 +108,14 @@ # Test script is run here. We create the file first, then append to it, # to ameliorate tests themselves also writing to the log file. Our tests # don't, but others can (automake bug#35762). +# OVPN changes: +# - add tee to see output of tests +# - needs portable pipefail mechanism +estatusfile="${trs_file}.exit" : >"$log_file" -"$@" >>"$log_file" 2>&1 -estatus=$? +("$@" 2>&1; estatus=$?; echo $estatus >"$estatusfile") | tee -a "$log_file" +estatus=$(cat "$estatusfile") +rm -f "$estatusfile" if test $enable_hard_errors = no && test $estatus -eq 99; then tweaked_estatus=1