From 8cf8e140bd5ff48ed405c2db37e5e7c6ed099761 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Wed, 15 May 2024 18:36:59 -0400 Subject: [PATCH 01/10] wip --- test/CMakeLists.txt | 16 ++++------------ test/gw-ci/CMakeLists.txt | 9 +++++++++ test/gw-ci/create_exp.sh | 16 ++++++++++++++++ 3 files changed, 29 insertions(+), 12 deletions(-) create mode 100644 test/gw-ci/CMakeLists.txt create mode 100755 test/gw-ci/create_exp.sh diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 86b53a3f1..c045655b4 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -134,19 +134,11 @@ if (WORKFLOW_TESTS) WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/test/testrun) endif() -# fv3jedi tests if (${BUILD_GDASBUNDLE}) - add_subdirectory(fv3jedi) -endif() - -# soca tests -if (${BUILD_GDASBUNDLE}) - add_subdirectory(soca) -endif() - -# snow da tests -if (${BUILD_GDASBUNDLE}) - add_subdirectory(snow) + add_subdirectory(fv3jedi) # fv3jedi tests + add_subdirectory(soca) # soca tests + add_subdirectory(snow) # snow da tests + add_subdirectory(gw-ci) # replicate the creation of some of the gw-ci tests endif() # gdas atm tests diff --git a/test/gw-ci/CMakeLists.txt b/test/gw-ci/CMakeLists.txt new file mode 100644 index 000000000..be8205a62 --- /dev/null +++ b/test/gw-ci/CMakeLists.txt @@ -0,0 +1,9 @@ +# WCDA test similar to what is tested in the gw-ci +set(pslot wcda-gwci) +set(HOMEgfs ${CMAKE_SOURCE_DIR}/../../..) +set(RUNTESTS ${CMAKE_CURRENT_BINARY_DIR}/../../test/gw-ci) +set(YAML ${HOMEgfs}/ci/cases/pr/C48mx500_3DVarAOWCDA.yaml) + +add_test(NAME wcda_ci + COMMAND /bin/bash -c "${PROJECT_SOURCE_DIR}/test/gw-ci/create_exp.sh ${YAML} ${pslot} ${HOMEgfs} ${RUNTESTS}" + WORKING_DIRECTORY ${RUNTESTS}) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh new file mode 100755 index 000000000..5605a1fbb --- /dev/null +++ b/test/gw-ci/create_exp.sh @@ -0,0 +1,16 @@ +#!/bin/bash +expyaml="$1" +export pslot="$2" +export HOMEgfs="$3" +export RUNTESTS="$4" + +echo "pslot: ${pslot}" +echo "HOMEgfs: ${HOMEgfs}" +echo "expyaml: ${expyaml}" +exit 0 + +# Source the gw environement +source ${HOMEgfs}/workflow/gw_setup.sh + +# Create the experiment +${HOMEgfs}/workflow/create_experiment.py --yaml "${expyaml}" From e0dfc4333128c3f884146eadb42f4aae80c80e03 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Thu, 16 May 2024 19:21:52 +0000 Subject: [PATCH 02/10] wip --- test/gw-ci/create_exp.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index 5605a1fbb..cc6a7ed2a 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -2,15 +2,17 @@ expyaml="$1" export pslot="$2" export HOMEgfs="$3" -export RUNTESTS="$4" +export RUNTESTS="$4"/${pslot} +export ICSDIR_ROOT=/scratch1/NCEPDEV/global/glopara/data/ICSDIR +export SLURM_ACCOUNT="da-cpu" echo "pslot: ${pslot}" echo "HOMEgfs: ${HOMEgfs}" echo "expyaml: ${expyaml}" -exit 0 # Source the gw environement -source ${HOMEgfs}/workflow/gw_setup.sh +${HOMEgfs}/workflow/gw_setup.sh # Create the experiment -${HOMEgfs}/workflow/create_experiment.py --yaml "${expyaml}" +#rm -r ${RUNTESTS} +${HOMEgfs}/workflow/create_experiment.py --yaml ${expyaml} From d99c7f9b9542b446474d3caa35ddcb4d9e39aeb4 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Thu, 16 May 2024 21:52:08 +0000 Subject: [PATCH 03/10] added 3 gw-ci test --- ci/run_ci.sh | 2 +- test/gw-ci/CMakeLists.txt | 18 ++++++++++++------ test/gw-ci/create_exp.sh | 2 +- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/ci/run_ci.sh b/ci/run_ci.sh index 200cfd61b..b62f78a88 100755 --- a/ci/run_ci.sh +++ b/ci/run_ci.sh @@ -61,7 +61,7 @@ module use $GDAS_MODULE_USE module load GDAS/$TARGET echo "---------------------------------------------------" >> $outfile rm -rf log.ctest -ctest -R gdasapp --output-on-failure &>> log.ctest +ctest -E "manual" -R gdasapp --output-on-failure &>> log.ctest ctest_status=$? npassed=$(cat log.ctest | grep "tests passed") if [ $ctest_status -eq 0 ]; then diff --git a/test/gw-ci/CMakeLists.txt b/test/gw-ci/CMakeLists.txt index be8205a62..60aca9832 100644 --- a/test/gw-ci/CMakeLists.txt +++ b/test/gw-ci/CMakeLists.txt @@ -1,9 +1,15 @@ -# WCDA test similar to what is tested in the gw-ci -set(pslot wcda-gwci) +# Setup the environement set(HOMEgfs ${CMAKE_SOURCE_DIR}/../../..) set(RUNTESTS ${CMAKE_CURRENT_BINARY_DIR}/../../test/gw-ci) -set(YAML ${HOMEgfs}/ci/cases/pr/C48mx500_3DVarAOWCDA.yaml) -add_test(NAME wcda_ci - COMMAND /bin/bash -c "${PROJECT_SOURCE_DIR}/test/gw-ci/create_exp.sh ${YAML} ${pslot} ${HOMEgfs} ${RUNTESTS}" - WORKING_DIRECTORY ${RUNTESTS}) +# List of g-w ci test to create +set(cycling_tests "C48mx500_3DVarAOWCDA" "C96_atmaerosnowDA" "C96C48_ufs_hybatmDA") + +# Prepare the cycling ctests +foreach(pslot ${cycling_tests}) + set(YAML ${HOMEgfs}/ci/cases/pr/${pslot}.yaml) + add_test(NAME ${pslot} + COMMAND /bin/bash -c "${PROJECT_SOURCE_DIR}/test/gw-ci/create_exp.sh ${YAML} ${pslot} ${HOMEgfs} ${RUNTESTS}" + WORKING_DIRECTORY ${RUNTESTS}) + set_tests_properties(${pslot} PROPERTIES LABELS "manual") +endforeach() diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index cc6a7ed2a..6a0e6d692 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -1,7 +1,7 @@ #!/bin/bash expyaml="$1" export pslot="$2" -export HOMEgfs="$3" +HOMEgfs="$3" export RUNTESTS="$4"/${pslot} export ICSDIR_ROOT=/scratch1/NCEPDEV/global/glopara/data/ICSDIR export SLURM_ACCOUNT="da-cpu" From 6dc6139b0410c26ade2aaf0e156cac4501dbed29 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 12:19:55 +0000 Subject: [PATCH 04/10] overwrite exp --- test/gw-ci/create_exp.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index 6a0e6d692..dc1e3e06e 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -6,13 +6,8 @@ export RUNTESTS="$4"/${pslot} export ICSDIR_ROOT=/scratch1/NCEPDEV/global/glopara/data/ICSDIR export SLURM_ACCOUNT="da-cpu" -echo "pslot: ${pslot}" -echo "HOMEgfs: ${HOMEgfs}" -echo "expyaml: ${expyaml}" - # Source the gw environement ${HOMEgfs}/workflow/gw_setup.sh # Create the experiment -#rm -r ${RUNTESTS} -${HOMEgfs}/workflow/create_experiment.py --yaml ${expyaml} +${HOMEgfs}/workflow/create_experiment.py --yaml ${expyaml} --overwrite From 7b551a595da087e8365a9657708ee45afdb8ef19 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 13:12:26 +0000 Subject: [PATCH 05/10] don't spec icsdir --- test/gw-ci/create_exp.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index dc1e3e06e..a1d2b2a51 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -3,7 +3,6 @@ expyaml="$1" export pslot="$2" HOMEgfs="$3" export RUNTESTS="$4"/${pslot} -export ICSDIR_ROOT=/scratch1/NCEPDEV/global/glopara/data/ICSDIR export SLURM_ACCOUNT="da-cpu" # Source the gw environement From e445f27bd7e727c63e7a11b588e868d8979435b6 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 09:14:03 -0400 Subject: [PATCH 06/10] don't spec. icsdir --- test/gw-ci/create_exp.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index dc1e3e06e..a1d2b2a51 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -3,7 +3,6 @@ expyaml="$1" export pslot="$2" HOMEgfs="$3" export RUNTESTS="$4"/${pslot} -export ICSDIR_ROOT=/scratch1/NCEPDEV/global/glopara/data/ICSDIR export SLURM_ACCOUNT="da-cpu" # Source the gw environement From a4063d39b5f509c53d8ffa814ab2a5d3b088aad9 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 15:35:35 +0000 Subject: [PATCH 07/10] post is broken --- test/soca/gw/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/soca/gw/CMakeLists.txt b/test/soca/gw/CMakeLists.txt index 38cea0d23..bb8f24385 100644 --- a/test/soca/gw/CMakeLists.txt +++ b/test/soca/gw/CMakeLists.txt @@ -48,7 +48,8 @@ set(jjob_list "JGLOBAL_PREP_OCEAN_OBS" "JGDAS_GLOBAL_OCEAN_ANALYSIS_ECEN" # "JGDAS_GLOBAL_OCEAN_ANALYSIS_LETKF" "JGDAS_GLOBAL_OCEAN_ANALYSIS_CHKPT" - "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST") +# TODO(WaterPeople) Add back when g-w PR2584 is merged +# "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST") # TODO(WaterPeople) Add back to the list of tested jobs once fixed # "JGDAS_GLOBAL_OCEAN_ANALYSIS_VRFY") From 0ddcb809d1c821ccaf7a6a90a96d361041654dd4 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 15:42:29 +0000 Subject: [PATCH 08/10] I broke post ... waiting for gw2584 --- test/soca/gw/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/soca/gw/CMakeLists.txt b/test/soca/gw/CMakeLists.txt index 38cea0d23..407c2759d 100644 --- a/test/soca/gw/CMakeLists.txt +++ b/test/soca/gw/CMakeLists.txt @@ -48,7 +48,8 @@ set(jjob_list "JGLOBAL_PREP_OCEAN_OBS" "JGDAS_GLOBAL_OCEAN_ANALYSIS_ECEN" # "JGDAS_GLOBAL_OCEAN_ANALYSIS_LETKF" "JGDAS_GLOBAL_OCEAN_ANALYSIS_CHKPT" - "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST") +# TODO(WaterPeople) Add back after g-w pr2584 is merged +# "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST") # TODO(WaterPeople) Add back to the list of tested jobs once fixed # "JGDAS_GLOBAL_OCEAN_ANALYSIS_VRFY") From 0627360a1b8a047813024975197708e2871722ff Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Fri, 17 May 2024 13:17:46 -0400 Subject: [PATCH 09/10] oops ... --- test/soca/gw/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/soca/gw/CMakeLists.txt b/test/soca/gw/CMakeLists.txt index 407c2759d..9d9320ed7 100644 --- a/test/soca/gw/CMakeLists.txt +++ b/test/soca/gw/CMakeLists.txt @@ -49,9 +49,10 @@ set(jjob_list "JGLOBAL_PREP_OCEAN_OBS" # "JGDAS_GLOBAL_OCEAN_ANALYSIS_LETKF" "JGDAS_GLOBAL_OCEAN_ANALYSIS_CHKPT" # TODO(WaterPeople) Add back after g-w pr2584 is merged -# "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST") +# "JGDAS_GLOBAL_OCEAN_ANALYSIS_POST" # TODO(WaterPeople) Add back to the list of tested jobs once fixed # "JGDAS_GLOBAL_OCEAN_ANALYSIS_VRFY") +) set(setup "") foreach(jjob ${jjob_list}) From ef25435356117a01704b6345e9301d5d7e9c2d70 Mon Sep 17 00:00:00 2001 From: Guillaume Vernieres Date: Mon, 20 May 2024 14:32:42 +0000 Subject: [PATCH 10/10] I lied ... ICSDIR_ROOT needs to be defined --- test/gw-ci/create_exp.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/gw-ci/create_exp.sh b/test/gw-ci/create_exp.sh index a1d2b2a51..4a6d2b34e 100755 --- a/test/gw-ci/create_exp.sh +++ b/test/gw-ci/create_exp.sh @@ -5,8 +5,12 @@ HOMEgfs="$3" export RUNTESTS="$4"/${pslot} export SLURM_ACCOUNT="da-cpu" +# Get ICSDIR_ROOT +source "${HOMEgfs}/ush/detect_machine.sh" +source "${HOMEgfs}/ci/platforms/config.${MACHINE_ID}" + # Source the gw environement -${HOMEgfs}/workflow/gw_setup.sh +source ${HOMEgfs}/workflow/gw_setup.sh # Create the experiment ${HOMEgfs}/workflow/create_experiment.py --yaml ${expyaml} --overwrite