libnbd/0004-dump-Fix-tests-on-Debian-10.patch

42 lines
1.1 KiB
Diff

From e7a2815412891d5c13b5b5f0e9aa61882880c87f Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Thu, 30 Jun 2022 22:31:00 +0100
Subject: [PATCH] dump: Fix tests on Debian 10
The version of nbdkit on Debian 10 does not set $uri. Check for this
or skip the test.
(cherry picked from commit 083b1ca30fb5e6e0dc0e4b0eea9ebe8474d3f864)
---
dump/dump-data.sh | 1 +
dump/dump-pattern.sh | 1 +
2 files changed, 2 insertions(+)
diff --git a/dump/dump-data.sh b/dump/dump-data.sh
index 955cd3b..46e4d1e 100755
--- a/dump/dump-data.sh
+++ b/dump/dump-data.sh
@@ -23,6 +23,7 @@ set -x
requires nbdkit --version
requires nbdkit data --dump-plugin
+requires nbdkit -U - null --run 'test "$uri" != ""'
output=dump-data.out
rm -f $output
diff --git a/dump/dump-pattern.sh b/dump/dump-pattern.sh
index d512b77..e2188ac 100755
--- a/dump/dump-pattern.sh
+++ b/dump/dump-pattern.sh
@@ -23,6 +23,7 @@ set -x
requires nbdkit --version
requires nbdkit pattern --dump-plugin
+requires nbdkit -U - null --run 'test "$uri" != ""'
output=dump-pattern.out
rm -f $output
--
2.31.1