Debian Codegraph @

exodus/cbind/test/testall.standalone

raw
1 # Copyright (c) 2005 Sandia Corporation. Under the terms of Contract
2 # DE-AC04-94AL85000 with Sandia Corporation, the U.S. Governement
3 # retains certain rights in this software.
4 #
5 # Redistribution and use in source and binary forms, with or without
6 # modification, are permitted provided that the following conditions are
7 # met:
8 #
9 # * Redistributions of source code must retain the above copyright
10 # notice, this list of conditions and the following disclaimer.
11 #
12 # * Redistributions in binary form must reproduce the above
13 # copyright notice, this list of conditions and the following
14 # disclaimer in the documentation and/or other materials provided
15 # with the distribution.
16 #
17 # * Neither the name of Sandia Corporation nor the names of its
18 # contributors may be used to endorse or promote products derived
19 # from this software without specific prior written permission.
20 #
21 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 #
33
34 # script to run all tests and compare them to saved dump files.
35 #
36 # To run the tests with valgrind checking, uncomment the next line and comment the
37 # following line. Can also define other prefixes if wanted.
38
39 if ($#argv == 0) then
40 set NCDUMP = `which ncdump`
41 else
42 set NCDUMP = $1
43 endif
44
45 #set PREFIX = "valgrind --tool=memcheck"
46 set PREFIX = ""
47 set SRCDIR = .
48 set DIFF = "diff -w"
49 echo "************************************************************************"
50 echo "************************************************************************"
51 rm -f test.output
52 echo "testwt - single precision write test..."
53 echo "begin testwt" > test.output
54 ${PREFIX} ${SRCDIR}/testwt >> test.output
55 echo "end testwt" >> test.output
56 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/test.dmp | tee testwt.res
57
58 echo "testrd - single precision read test..."
59 echo "begin testrd" >> test.output
60 ${PREFIX} ${SRCDIR}/testrd | grep -v version | ${DIFF} - ${SRCDIR}/testrd.dmp | tee testrd.res
61 echo "end testrd" >> test.output
62
63 echo "testcp_ss - single-to-single precision copy test..."
64 echo "begin testcp_ss" >> test.output
65 ${PREFIX} ${SRCDIR}/testcp >> test.output
66 echo "end testcp_ss" >> test.output
67 ${NCDUMP} -d5,5 testcp.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_ss.dmp | tee testcp_ss.res
68
69 echo "testcp_sd - single-to-double precision copy test..."
70 echo "begin testcp_sd" >> test.output
71 ${PREFIX} ${SRCDIR}/testcpd >> test.output
72 echo "end testcp_sd" >> test.output
73 ${NCDUMP} -d5,5 testcpd.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_sd.dmp | tee testcp_sd.res
74
75 echo "testcp_ln - large model to normal model single precision copy test..."
76 echo "begin testcp_ln" >> test.output
77 ${PREFIX} ${SRCDIR}/testcp_ln >> test.output
78 echo "end testcp_ln" >> test.output
79 ${NCDUMP} -d5,5 testcp.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_ln.dmp | tee testcp_ln.res
80
81 echo "testcp_nl - normal_model to large_model single precision copy test..."
82 echo "begin testcp_nl" >> test.output
83 ${PREFIX} ${SRCDIR}/testcp_nl >> test.output
84 echo "end testcp_nl" >> test.output
85 ${NCDUMP} -d5,5 testcp_nl.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_nl.dmp | tee testcp_nl.res
86
87 echo "testwt_clb - single precision write test using concatenated puts..."
88 echo "begin testwt_clb" >> test.output
89 ${PREFIX} ${SRCDIR}/testwt_clb >> test.output
90 echo "end testwt_clb" >> test.output
91 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/test_clb.dmp | tee testwt_clb.res
92
93 echo "testwtd - double precision write test..."
94 echo "begin testwtd" >> test.output
95 ${PREFIX} ${SRCDIR}/testwtd >> test.output
96 echo "end testwtd" >> test.output
97 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/testd.dmp | tee testwtd.res
98
99 echo "testrdd - double precision read test..."
100 echo "begin testrdd" >> test.output
101 ${PREFIX} ${SRCDIR}/testrdd | grep -v version | ${DIFF} - ${SRCDIR}/testrdd.dmp | tee testrdd.res
102 echo "end testrdd" >> test.output
103
104 echo "testcp_dd - double-to-double precision copy test..."
105 echo "begin testcp_dd" >> test.output
106 ${PREFIX} ${SRCDIR}/testcpd >> test.output
107 echo "end testcp_dd" >> test.output
108 ${NCDUMP} -d5,5 testcpd.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_dd.dmp | tee testcp_dd.res
109
110 echo "testcp_ds - double-to-single precision copy test..."
111 echo "begin testcp_ds" >> test.output
112 ${PREFIX} ${SRCDIR}/testcp >> test.output
113 echo "end testcp_ds" >> test.output
114 ${NCDUMP} -d5,5 testcp.exo | grep -v version | ${DIFF} - ${SRCDIR}/testcp_ds.dmp | tee testcp_ds.res
115
116 echo "testwt1 - single precision write files with several side sets..."
117 echo "testwt1 ... [Expect WEDGE6 warning from this test]"
118 echo "begin testwt1" >> test.output
119 ${PREFIX} ${SRCDIR}/testwt1 >> test.output
120 echo "end testwt1" >> test.output
121 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/test1.dmp | tee testwt1.res
122
123 echo "testrd1 - single precision read test of a file with several side sets..."
124 echo "testrd1 ... [Expect file create failure error, NOCLOBBER]"
125 echo "testrd1 ... [Expect failure locating elem var 1 for elem block 12]"
126 echo "begin testrd1" >> test.output
127 ${PREFIX} ${SRCDIR}/testrd1 | grep -v version | ${DIFF} - ${SRCDIR}/testrd1.dmp | tee testrd1.res
128 echo "end testrd1" >> test.output
129
130 echo "testwt_ss - write files to test side sets..."
131 echo "testwt_ss ... [Expect WEDGE6 warning from this test]"
132 echo "begin testwt_ss" >> test.output
133 ${PREFIX} ${SRCDIR}/testwt_ss >> test.output
134 echo "end testwt_ss" >> test.output
135 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt_ss.dmp | tee testwt_ss.res
136
137 echo "testrd_ss - read test of a file with several side sets..."
138 echo "testrd_ss ... [Expect warning for NULL sidesets 30 and 31]"
139 echo "begin testrd_ss" >> test.output
140 ${PREFIX} ${SRCDIR}/testrd_ss | grep -v version | ${DIFF} - ${SRCDIR}/testrd_ss.dmp | tee testrd_ss.res
141 echo "end testrd_ss" >> test.output
142
143 echo "testwt2 - single precision write 2 files (simultaneously open) test..."
144 echo "begin testwt2" >> test.output
145 ${PREFIX} ${SRCDIR}/testwt2 >> test.output
146 echo "end testwt2" >> test.output
147 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/test2-1.dmp | tee testwt2-1.res
148 ${NCDUMP} -d5,5 test2.exo | grep -v version | ${DIFF} - ${SRCDIR}/test2-2.dmp | tee testwt2-2.res
149
150 echo "testrdwt - read from one and write to another (simutaneously open) file..."
151 echo "begin testrdwt" >> test.output
152 ${PREFIX} ${SRCDIR}/testrdwt >> test.output
153 echo "end testrdwt" >> test.output
154 ${NCDUMP} -d5,5 test2.exo | grep -v version | ${DIFF} - ${SRCDIR}/test2.dmp | tee testrdwt.res
155
156 echo "testwt_nc - write x y z components of coordinates separately..."
157 echo "begin testwt_nc" >> test.output
158 ${PREFIX} ${SRCDIR}/testwt_nc >> test.output
159 echo "end testwt_nc" >> test.output
160 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/test.dmp | tee testwt_nc.res
161
162 echo "testrd_nc - read x y z components of coordinates separately..."
163 echo "begin testrd_nc" >> test.output
164 ${PREFIX} ${SRCDIR}/testrd_nc | grep -v version | ${DIFF} - ${SRCDIR}/testrd_nc.dmp | tee testrd_nc.res
165 echo "end testrd" >> test.output
166
167 echo "testwt-zeron - write file with zero nodes and elements..."
168 echo "begin testwt-zeron" >> test.output
169 ${PREFIX} ${SRCDIR}/testwt-zeron >> test.output
170 echo "end testwt-zeron" >> test.output
171 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt-zeron.dmp | tee testwt-zeron.res
172
173 echo "testrd - read test of file with zero nodes and elements..."
174 echo "begin testrd zero nodes" >> test.output
175 ${PREFIX} ${SRCDIR}/testrd | grep -v version | ${DIFF} - ${SRCDIR}/testrd_zeron.dmp | tee testrd_zeron.res
176 echo "end testrd zero nodes" >> test.output
177
178 echo "testwt-zeroe - write file with zero elements..."
179 echo "begin testwt-zeroe" >> test.output
180 ${PREFIX} ${SRCDIR}/testwt-zeroe >> test.output
181 echo "end testwt-zeroe" >> test.output
182 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt-zeroe.dmp | tee testwt-zeroe.res
183
184 echo "testrd - read test of file with zero elements..."
185 echo "begin testrd zero elements" >> test.output
186 ${PREFIX} ${SRCDIR}/testrd | grep -v version | ${DIFF} - ${SRCDIR}/testrd_zeroe.dmp | tee testrd_zeroe.res
187 echo "end testrd zero elements" >> test.output
188
189 echo "testwt-one-attrib - read/write test of element attributes - read one at a time..."
190 echo "begin testwt-one-attrib - read attributes one at a time" >> test.output
191 ${PREFIX} ${SRCDIR}/testwt-one-attrib | tee testrd_zeroe.res
192 echo "end testwt-one-attrib - read attributes one at a time" >> test.output
193
194 echo "testwt-nsided - write file with nsided elements..."
195 echo "begin testwt-nsided" >> test.output
196 ${PREFIX} ${SRCDIR}/testwt-nsided >> test.output
197 echo "end testwt-nsided" >> test.output
198 ${NCDUMP} -d5,5 test-nsided.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt-nsided.dmp | tee testwt-nsided.res
199
200 echo "testrd-nsided - read file with nsided elements..."
201 echo "begin testrd-nsided" >> test.output
202 ${PREFIX} ${SRCDIR}/testrd-nsided | grep -v version | ${DIFF} - ${SRCDIR}/testrd-nsided.dmp | tee testrd-nsided.res
203 echo "end testrd-nsided" >> test.output
204
205 echo "testwt-nfaced - write file with nfaced elements..."
206 echo "begin testwt-nfaced" >> test.output
207 ${PREFIX} ${SRCDIR}/testwt-nfaced >> test.output
208 echo "end testwt-nfaced" >> test.output
209 ${NCDUMP} -d5,5 test-nfaced.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt-nfaced.dmp | tee testwt-nfaced.res
210
211 echo "testrd-nfaced - read file with nfaced elements..."
212 echo "begin testrd-nfaced" >> test.output
213 ${PREFIX} ${SRCDIR}/testrd-nfaced | grep -v version | ${DIFF} - ${SRCDIR}/testrd-nfaced.dmp | tee testrd-nfaced.res
214 echo "end testrd-nfaced" >> test.output
215
216 echo "testwt-long-name - write file with long (64-character) names..."
217 echo "begin testwt-long-name" >> test.output
218 ${PREFIX} ${SRCDIR}/testwt-long-name >> test.output
219 echo "end testwt-long-name" >> test.output
220 ${NCDUMP} -d5,5 test.exo | grep -v version | ${DIFF} - ${SRCDIR}/testwt-long-name.dmp | tee testwt-long-name.res
221
222 echo "testrd - read long name file truncating to 32 characters on read..."
223 echo "begin testrd (truncate)" >> test.output
224 ${PREFIX} ${SRCDIR}/testrd | grep -v version | ${DIFF} - ${SRCDIR}/testrd-nm32.dmp | tee testrd-nm32.res
225 echo "end testrd (truncate)" >> test.output
226
227 echo "testrd-long-name - read long name file..."
228 echo "begin testrd-long-name" >> test.output
229 ${PREFIX} ${SRCDIR}/testrd-long-name | grep -v version | ${DIFF} - ${SRCDIR}/testrd-long-name.dmp | tee testrd-long-name.res
230 echo "end testrd-long-name" >> test.output
231
232 echo "test_nemesis - read long name file..."
233 echo "begin test_nemesis" >> test.output
234 ${PREFIX} ${SRCDIR}/test_nemesis | grep -v version | ${DIFF} - ${SRCDIR}/test_nemesis.dmp | tee test_nemesis.res
235 echo "end test_nemesis" >> test.output
236
237 echo "************************************************************************"
238 echo "************************************************************************"