From 722eb1fe8ac9c77d9af013ffdfe364b042c2c718 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= Date: Wed, 17 May 2017 11:42:35 +0200 Subject: [PATCH] zfstest: skip tests if ZFS is not available MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fabian Grünbichler --- test/run_test_zfspoolplugin.pl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/run_test_zfspoolplugin.pl b/test/run_test_zfspoolplugin.pl index f07eacc..b70aad8 100755 --- a/test/run_test_zfspoolplugin.pl +++ b/test/run_test_zfspoolplugin.pl @@ -2658,6 +2658,11 @@ sub volume_is_base { return $isBase; } +eval { run_command("zpool status"); }; +if ($@) { + warn "zpool status failed, not running tests: $@\n"; + exit 0; +} setup_zpool();