So one thing we could do for this test is to require (for the test) that /bin/sh is bash, something like the patch below. I was only able to test this in the positive case.
diff --git a/tests/test-log-script-info.sh b/tests/test-log-script-info.sh index fa9b2ed32..d65f6415d 100755 --- a/tests/test-log-script-info.sh +++ b/tests/test-log-script-info.sh @@ -38,6 +38,10 @@ requires_run requires_nbdinfo requires_filter log +# This test implicitly assumes /bin/sh is bash, see: +# https://listman.redhat.com/archives/libguestfs/2023-October/032767.html +BASH_VERSION=no requires /bin/sh -c 'test "x$BASH_VERSION" != "xno"' + if ! nbdinfo --help | grep -- --map ; then echo "$0: nbdinfo --map option required to run this test" exit 77 -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-builder quickly builds VMs from scratch http://libguestfs.org/virt-builder.1.html _______________________________________________ Libguestfs mailing list Libguestfs@redhat.com https://listman.redhat.com/mailman/listinfo/libguestfs