From 405c923c45aab0a4d4e96a0adf8b0d9da6a98854 Mon Sep 17 00:00:00 2001 From: Lauren Chilutti Date: Wed, 26 Jul 2023 13:42:11 -0400 Subject: [PATCH] removing a 1 at the beginning of a line that seems to be a typo, and rewriting a few lines of code in diag_manager test test_diag_update_buffer.F90 --- test_fms/diag_manager/test_diag_manager2.sh | 4 +++- test_fms/diag_manager/test_diag_update_buffer.F90 | 8 ++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/test_fms/diag_manager/test_diag_manager2.sh b/test_fms/diag_manager/test_diag_manager2.sh index 747be8e691..a625db4d1e 100755 --- a/test_fms/diag_manager/test_diag_manager2.sh +++ b/test_fms/diag_manager/test_diag_manager2.sh @@ -460,6 +460,7 @@ test_expect_success "Unstructured grid (test $my_test_count)" ' mpirun -n 1 ../test_diag_manager ' +my_test_count=24 # test_diag_manager_time cat <<_EOF > diag_table test_diag_manager @@ -478,6 +479,7 @@ test_diag_manager "test_diag_manager_mod", "sst", "sst", "ocn_end%4yr%2mo%2dy%2hr", "all", .true., "none", 2 _EOF +my_test_count=25 rm -f input.nml && touch input.nml test_expect_success "wildcard filenames (test $my_test_count)" ' mpirun -n 1 ../test_diag_manager_time @@ -501,7 +503,7 @@ test_expect_success "diurnal test (test $my_test_count)" ' mpirun -n 1 ../test_diag_manager_time ' setup_test -my_test_count=`expr $my_test_count + 1` +my_test_count=26 test_expect_success "Test the diag update_buffer (test $my_test_count)" ' mpirun -n 1 ../test_diag_update_buffer ' diff --git a/test_fms/diag_manager/test_diag_update_buffer.F90 b/test_fms/diag_manager/test_diag_update_buffer.F90 index 67de3ec665..9ca4f93198 100644 --- a/test_fms/diag_manager/test_diag_update_buffer.F90 +++ b/test_fms/diag_manager/test_diag_update_buffer.F90 @@ -282,12 +282,12 @@ SUBROUTINE init_field_values (field) DO k = 1, NZ DO j = 1, NY DO i = 1, NX + itemp = get_array_index_from_4D(i,j,k,l,NX,NY,NZ) SELECT TYPE ( field) TYPE IS (real(kind=r4_kind)) - itemp = get_array_index_from_4D(i,j,k,l,NX,NY,NZ) - field(i,j,k,l) = get_array_index_from_4D(i,j,k,l,NX,NY,NZ) -1 TYPE IS (integer(kind=i8_kind)) - field(i,j,k,l) = get_array_index_from_4D(i,j,k,l,NX,NY,NZ) + field(i,j,k,l) = real(itemp, kind=r4_kind) + TYPE IS (integer(kind=i8_kind)) + field(i,j,k,l) = int(itemp, kind=i8_kind) END SELECT END DO END DO