svn commit: r329229 - projects/zfsd/head/tests/sys/cddl/zfs/tests/cli_root/zfs_rename

Alan Somers asomers at FreeBSD.org
Tue Feb 13 17:44:55 UTC 2018


Author: asomers
Date: Tue Feb 13 17:44:54 2018
New Revision: 329229
URL: https://svnweb.freebsd.org/changeset/base/329229

Log:
  Remove the cleanup step in zfs_rename_009_neg
  
  tests/sys/cddl/zfs/tests/cli_root/zfs_rename/zfs_rename_009_neg.ksh
  	Remove the cleanup step.  It's redundant with the standard cleanup
  	in cleanup.ksh.
  
  Sponsored by:	Spectra Logic Corp

Modified:
  projects/zfsd/head/tests/sys/cddl/zfs/tests/cli_root/zfs_rename/zfs_rename_009_neg.ksh

Modified: projects/zfsd/head/tests/sys/cddl/zfs/tests/cli_root/zfs_rename/zfs_rename_009_neg.ksh
==============================================================================
--- projects/zfsd/head/tests/sys/cddl/zfs/tests/cli_root/zfs_rename/zfs_rename_009_neg.ksh	Tue Feb 13 17:43:54 2018	(r329228)
+++ projects/zfsd/head/tests/sys/cddl/zfs/tests/cli_root/zfs_rename/zfs_rename_009_neg.ksh	Tue Feb 13 17:44:54 2018	(r329229)
@@ -63,32 +63,7 @@ if (($? != 0)); then
 	log_unsupported
 fi
 
-function cleanup
-{
-	typeset snaps=$($ZFS list -H -t snapshot -o name)
-	typeset exclude
-	typeset snap
-	typeset pool_name
-
-	if [[ -n $KEEP ]]; then
-		exclude=`eval $ECHO \"'(${KEEP})'\"`
-	fi
-	
-	for snap in $snaps; do
-		pool_name=$($ECHO "$snap" | $AWK -F/ '{print $1}')
-		if [[ -n $exclude ]]; then
-			$ECHO "$pool_name" | $EGREP -v "$exclude" > /dev/null 2>&1
-			if [[ $? -eq 0 ]]; then
-				log_must $ZFS destroy $snap
-			fi
-		else
-			log_must $ZFS destroy $snap
-		fi
-	done
-}
-
 log_assert "zfs rename -r failed, when snapshot name is already existing."
-log_onexit cleanup
 
 set -A datasets $TESTPOOL		$TESTPOOL/$TESTCTR \
 	$TESTPOOL/$TESTCTR/$TESTFS1	$TESTPOOL/$TESTFS


More information about the svn-src-projects mailing list