Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libcdi
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mpim-sw
libcdi
Commits
aec448f7
Commit
aec448f7
authored
3 years ago
by
Sergey Kosukhin
Browse files
Options
Downloads
Patches
Plain Diff
Avoid random names for the files generated by the tests.
parent
e8821d8e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!34
Version 2.2.0
,
!13
Consolidation with CDI-PIO (develop)
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
tests/test_cdf_const.in
+9
-6
9 additions, 6 deletions
tests/test_cdf_const.in
tests/test_cdf_transformation.in
+1
-1
1 addition, 1 deletion
tests/test_cdf_transformation.in
tests/test_f2003.in
+6
-3
6 additions, 3 deletions
tests/test_f2003.in
with
16 additions
and
10 deletions
tests/test_cdf_const.in
+
9
−
6
View file @
aec448f7
#!@SHELL@
test 'x@ENABLE_NETCDF@' = xyes || exit 77
cdi_app_stdout="$0.cdi_app.stdout"
cdi_app_stderr="$0.cdi_app.stderr"
exec >test_cdf_const.log 2>&1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/examples/cdi_write_const || exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/app/cdi -s example_const.nc >cdi
.$$.
stdout 2>cdi
.$$.
stderr || exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/app/cdi example_const.nc >>cdi
.$$.
stdout 2>>cdi
.$$.
stderr || exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/app/cdi -s example_const.nc >
${
cdi
_app_
stdout
}
2>
${
cdi
_app_
stderr
}
|| exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/app/cdi example_const.nc >>
${
cdi
_app_
stdout
}
2>>
${
cdi
_app_
stderr
}
|| exit 1
echo "$0"
exec 6<cdi
.$$.
stdout 7<"$0"
exec 6<
${
cdi
_app_
stdout
}
7<"$0"
while read pattern <&7 ; do
test "x$pattern" != 'x#PATTERNS' || break
...
...
@@ -21,9 +24,9 @@ while read line <&6 ; do
echo "$line" | grep "$pattern" || exit 1
done
if test -s cdi
.$$.
stderr; then
if test -s
${
cdi
_app_
stderr
}
; then
echo "unexpected error message from @abs_top_builddir@/app/cdi:"
cat cdi
.$$.
stderr
cat
${
cdi
_app_
stderr
}
exit 1
fi
...
...
@@ -31,7 +34,7 @@ read pattern <&7
test "x$pattern" = 'x#END PATTERNS' || exit 1
exec 5<&- 6<&-
\rm cdi
.$$.
stdout
cdi.$$.
stderr example_const.nc
\rm
${
cdi
_app_
stdout
} ${cdi_app_
stderr
}
example_const.nc
\rm test_cdf_const.log
#PATTERNS
...
...
This diff is collapsed.
Click to expand it.
tests/test_cdf_transformation.in
+
1
−
1
View file @
aec448f7
#!@SHELL@
test 'x@ENABLE_NETCDF@' = xyes || exit 77
ncdatafile="
test$
$.nc"
ncdatafile="$
0
.nc"
tempfiles="${ncdatafile}"
trap "EC=\$? ; \rm -f ${tempfiles}; exit \$EC" EXIT
...
...
This diff is collapsed.
Click to expand it.
tests/test_f2003.in
+
6
−
3
View file @
aec448f7
...
...
@@ -2,13 +2,16 @@
@CREATE_ISOC_FALSE@exit 77
test 'x@ENABLE_NETCDF@' = xyes || exit 77
cdi_read_f2003_stdout="$0.cdi_read_f2003.stdout"
cdi_read_f2003_stderr="$0.cdi_read_f2003.stderr"
format=nc
exec >test_f2003_$format.log 2>&1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/examples/cdi_write_f2003 || exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/examples/cdi_read_f2003 >cdi_read_f2003
.$$.
stdout 2>cdi_read_f2003
.$$.
stderr || exit 1
../libtool --mode=execute ${tool_wrap} @abs_top_builddir@/examples/cdi_read_f2003 >
${
cdi_read_f2003
_
stdout
}
2>
${
cdi_read_f2003
_
stderr
}
|| exit 1
echo "$0"
exec 5<cdi_read_f2003
.$$.
stdout 6<cdi_read_f2003
.$$.
stderr 7<"$0"
exec 5<
${
cdi_read_f2003
_
stdout
}
6<
${
cdi_read_f2003
_
stderr
}
7<"$0"
while read pattern <&7 ; do
test "x$pattern" != 'x#PATTERNS' || break
done
...
...
@@ -30,7 +33,7 @@ read pattern <&7
test "x$pattern" = 'x#END PATTERNS' || exit 1
exec 5<&- 6<&-
\rm cdi_read_f2003
.$$.
stdout
cdi_read_f2003
.$$.
stderr
\rm
${
cdi_read_f2003
_
stdout
} ${
cdi_read_f2003
_
stderr
}
\rm test_f2003_$format.log
#PATTERNS
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment