1 #! /usr/bin/ksh -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 2009 Sun Microsystems, Inc. All rights reserved.
25 # Use is subject to license terms.
26 #
27
28 #
29 # The main test case file for the offline subfunction of the stmfadm command.
30 # This file contains the test startup functions and the invocable component offline
31 # of all the test purposes that are to be executed.
32 #
33
34 #
35 # Set the tet global variables tet_startup and tet_cleanup to the
36 # startup and cleanup function names
37 #
38 tet_startup="startup"
39 tet_cleanup="cleanup"
40
41 #
42 # The offline of invocable components for this test case set.
43 # All the components are a 1:1 relation to each test purpose.
44 #
45 iclist="ic1 ic2 ic3 ic4 ic5 ic6 ic7 ic8 ic9 ic10"
46 iclist="$iclist ic11 ic12 ic13 ic14 ic15 ic16 ic17 ic18 ic19 ic20"
47 ic1="offline001"
48 ic2="offline002"
49 ic3="offline003"
50 ic4="offline004"
51 ic5="offline005"
52 ic6="offline006"
53 ic7="offline007"
54 ic8="offline008"
55 ic9="offline009"
56 ic10="offline010"
57 ic11="offline011"
58 ic12="offline012"
59 ic13="offline013"
60 ic14="offline014"
61 ic15="offline015"
62 ic16="offline016"
63 ic17="offline017"
64 ic18="offline018"
65 ic19="offline019"
66 ic20="offline020"
67 #
68 # Source in each of the test purpose files that are associated with
69 # each of the invocable components offlineed in the previous settings.
70 #
71 . ./tp_offline_stmfadm_001
72 . ./tp_offline_stmfadm_002
73 . ./tp_offline_stmfadm_003
74 . ./tp_offline_stmfadm_004
75 . ./tp_offline_stmfadm_005
76 . ./tp_offline_stmfadm_006
77 . ./tp_offline_stmfadm_007
78 . ./tp_offline_stmfadm_008
79 . ./tp_offline_stmfadm_009
80 . ./tp_offline_stmfadm_010
81 . ./tp_offline_stmfadm_011
82 . ./tp_offline_stmfadm_012
83 . ./tp_offline_stmfadm_013
84 . ./tp_offline_stmfadm_014
85 . ./tp_offline_stmfadm_015
86 . ./tp_offline_stmfadm_016
87 . ./tp_offline_stmfadm_017
88 . ./tp_offline_stmfadm_018
89 . ./tp_offline_stmfadm_019
90 . ./tp_offline_stmfadm_020
91
92 #
93 # The startup function that will be called when this test case is
94 # invoked before any test purposes are executed.
95 #
96 function startup
97 {
98 #
99 # Call the _startup function to initialize the system and
100 # verify the system resources and setup the filesystems to be
101 # used by the tests.
102 #
103 cti_report "Checking environment and runability"
104 comstar_startup_fc_target
105
106 }
107
108 #
109 # The cleanup function that will be called when this test case is
110 # invoked after all the test purposes are executed (or aborted).
111 #
112 function cleanup
113 {
114 #
115 # Call the _cleanup function to offline any filesystems that were
116 # in use and free any resource that might still be in use by the tests.
117 #
118 cti_report "Cleaning up after tests"
119 comstar_cleanup_fc_target
120 }
121
122
123 #
124 # Source in the common utilities and tools that are used by the test purposes
125 # and test case.
126 #
127 . ${CTI_SUITE}/lib/comstar_common
128
129 #
130 # Source in the cti and tet required utilities and tools.
131 #
132 . ${CTI_ROOT}/lib/ctiutils.ksh
133 . ${TET_ROOT}/lib/ksh/tcm.ksh