about summary refs log tree commit diff
path: root/Test
diff options
context:
space:
mode:
Diffstat (limited to 'Test')
-rw-r--r--Test/C02cond.ztst7
1 files changed, 6 insertions, 1 deletions
diff --git a/Test/C02cond.ztst b/Test/C02cond.ztst
index eafda1b5c..6c6aea4f6 100644
--- a/Test/C02cond.ztst
+++ b/Test/C02cond.ztst
@@ -52,7 +52,12 @@
   [[ -e zerolength && ! -e nonexistent ]]
 0:-e cond
 
-  [[ -f zerolength && ! -f cond && ! -f $char && ! -f $block && ! -f . ]]
+  if [[ -n $block ]]; then
+    [[ -f zerolength && ! -f cond && ! -f $char && ! -f $block[(f)1] && ! -f . ]]
+  else
+    print -u8 'Warning: Not testing [[ -f blockdevice ]] (no devices found)'
+    [[ -f zerolength && ! -f cond && ! -f $char && ! -f . ]]
+  fi
 0:-f cond
 
   [[ -g modish && ! -g zerolength ]]