Print this page
7290 ZFS test suite needs to control what utilities it can run
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>

@@ -24,11 +24,11 @@
 # Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
 # Use is subject to license terms.
 #
 
 #
-# Copyright (c) 2013 by Delphix. All rights reserved.
+# Copyright (c) 2013, 2016 by Delphix. All rights reserved.
 #
 
 . $STF_SUITE/include/libtest.shlib
 . $STF_SUITE/tests/functional/inuse/inuse.cfg
 

@@ -45,11 +45,11 @@
 
 verify_runnable "global"
 
 function cleanup
 {
-        poolexists $TESTPOOL1 || $ZPOOL import $TESTPOOL1 >/dev/null 2>&1
+        poolexists $TESTPOOL1 || zpool import $TESTPOOL1 >/dev/null 2>&1
 
         poolexists $TESTPOOL1 && destroy_pool $TESTPOOL1
 
         #
         # Tidy up the disks we used.

@@ -60,11 +60,11 @@
 function verify_assertion #slices
 {
         typeset targets=$1
 
         for t in $targets; do
-                $ECHO "y" | $NEWFS -v $t > /dev/null 2>&1
+                echo "y" | newfs -v $t > /dev/null 2>&1
                 (( $? !=0 )) && \
                         log_fail "newfs over exported pool " \
                                 "failes unexpected."
         done
 

@@ -91,11 +91,11 @@
                 (( i = i + 1 ))
                 continue
         fi
 
         create_pool $TESTPOOL1 ${vdevs[i]} $vslices spare $sslices
-        log_must $ZPOOL export $TESTPOOL1
+        log_must zpool export $TESTPOOL1
         verify_assertion "$rawtargets"
         cleanup_devices $vslices $sslices
 
         (( i = i + 1 ))
 done