Skip to content

Commit

Permalink
Fix errors in cice.setup script and add travis tests to catch this so…
Browse files Browse the repository at this point in the history
…oner (#406)

* add cice.setup --case and cice.setup --test script tests to the travis yml file

* fix cice.setup script
  • Loading branch information
apcraig committed Feb 18, 2020
1 parent 1561e76 commit 2e1c3b7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ install:
#-e 'mirror /archive/Model-Data/CICE/ ~/ICEPACK_INPUTDATA; quit'"

script:
# verify cice.setup --case and cice.setup --test don't error then run test suite
- "./cice.setup --case trcase --mach travisCI --env gnu --pes 2x2 -s diag1"
- "./cice.setup --test smoke --testid trtest --mach travisCI --env gnu
--pes 2x2 -s diag1"
- "./cice.setup --suite travis_suite --testid travisCItest
--mach travisCI --env gnu;
cd testsuite.travisCItest &&
Expand Down
13 changes: 6 additions & 7 deletions cice.setup
Original file line number Diff line number Diff line change
Expand Up @@ -389,13 +389,11 @@ else
cat ${tarray} >> $tsfile
else if (-e ${tarray}.ts) then
cat ${tarray}.ts >> $tsfile
else
if (-e ${ICE_SCRIPTS}/tests/${tarray}.ts) then
cat ${ICE_SCRIPTS}/tests/${tarray}.ts >> $tsfile
else
echo "${0}: ERROR, cannot find testsuite file ${tarray}, also checked ${ICE_SCRIPTS}/tests/${tarray}.ts"
exit -1
endif
else if (-e ${ICE_SCRIPTS}/tests/${tarray}.ts) then
cat ${ICE_SCRIPTS}/tests/${tarray}.ts >> $tsfile
else
echo "${0}: ERROR, cannot find testsuite file ${tarray}, also checked ${ICE_SCRIPTS}/tests/${tarray}.ts"
exit -1
endif
end
Expand All @@ -422,6 +420,7 @@ set dorun = false
set dosubmit = true
if (\$?SUITE_BUILD) then
set dobuild = "\${SUITE_BUILD}"
endif
if (\$?SUITE_RUN) then
set dorun = "\${SUITE_RUN}"
endif
Expand Down

0 comments on commit 2e1c3b7

Please sign in to comment.