1#! /usr/local/bin/ksh93 -p 2# 3# CDDL HEADER START 4# 5# The contents of this file are subject to the terms of the 6# Common Development and Distribution License (the "License"). 7# You may not use this file except in compliance with the License. 8# 9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10# or http://www.opensolaris.org/os/licensing. 11# See the License for the specific language governing permissions 12# and limitations under the License. 13# 14# When distributing Covered Code, include this CDDL HEADER in each 15# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16# If applicable, add the following below this CDDL HEADER, with the 17# fields enclosed by brackets "[]" replaced with your own identifying 18# information: Portions Copyright [yyyy] [name of copyright owner] 19# 20# CDDL HEADER END 21# 22 23# 24# Copyright 2012 Spectra Logic Corporation. All rights reserved. 25# Use is subject to license terms. 26# 27 28. $STF_SUITE/include/libtest.kshlib 29. $STF_SUITE/tests/zil/zil.kshlib 30 31############################################################################### 32# 33# __stc_assertion_start 34# 35# ID: zil_001_pos 36# 37# DESCRIPTION: 38# 39# XXX XXX XXX 40# 41# STRATEGY: 42# 1) XXX 43# 2) XXX 44# 45# TESTABILITY: explicit 46# 47# TEST_AUTOMATION_LEVEL: automated 48# 49# CODING_STATUS: COMPLETED (YYYY-MM-DD) XXX 50# 51# __stc_assertion_end 52# 53############################################################################### 54 55verify_runnable "both" 56 57function cleanup 58{ 59 log_must $LS -lr $TESTDIR 60 log_must $RM -rf $TESTDIR/* 61} 62 63log_onexit cleanup 64 65log_assert "Verify that basic files and directory operations work" 66 67zil_setup 68log_must $TOUCH $TESTDIR/0 69log_must $MV $TESTDIR/0 $TESTDIR/1 70log_must ln -s $TESTDIR/1 $TESTDIR/2 71log_must ln $TESTDIR/1 $TESTDIR/3 72log_must $MKDIR $TESTDIR/4 73log_must $RMDIR $TESTDIR/4 74 75zil_reimport_pool $TESTPOOL 76log_mustnot test -f $TESTDIR/0 77log_must test -f $TESTDIR/1 78log_must test -L $TESTDIR/2 79log_must test -e $TESTDIR/3 80log_mustnot test -d $TESTDIR/4 81 82log_pass "Success running basic files and directory operations" 83