Skip to content

Add unit testing for RRTMGP utilities#369

Open
peverwhee wants to merge 5 commits intoESCOMP:mainfrom
peverwhee:unit-testing-court
Open

Add unit testing for RRTMGP utilities#369
peverwhee wants to merge 5 commits intoESCOMP:mainfrom
peverwhee:unit-testing-court

Conversation

@peverwhee
Copy link
Collaborator

@peverwhee peverwhee commented Mar 9, 2026

Tag name (The PR title should also include the tag name): n/a
Originator(s): peverwhee

Description (include issue title and the keyword ['closes', 'fixes', 'resolves'] and issue number):

Adds unit tests for the following RRTMGP utilities (and small scheme):

  • schemes/rrtmgp/utils/rrtmgp_dry_static_energy_tendency.F90 (4 tests)
  • schemes/rrtmgp/utils/calculate_net_heating.F90 (2 tests)
  • schemes/rrtmgp/utils/radiation_tools.F90 (2 tests)
  • schemes/rrtmgp/utils/radiation_utils.F90 (21 tests)
  • schemes/rrtmgp/rrtmgp_sw_solar_var_setup.F90 (2 tests)

List all namelist files that were added or changed: n/a

List all files eliminated and why: n/a

List all files added and what they do:

A    test/unit-test/include/interpolate_stub.F90
- add stub so that radiation_tools.F90 will build

A    test/unit-test/tests/rrtmgp/CMakeLists.txt
A    test/unit-test/tests/rrtmgp/test_calculate_net_heating.pf
A    test/unit-test/tests/rrtmgp/test_radiation_tools.pf
A    test/unit-test/tests/rrtmgp/test_radiation_utils.pf
A    test/unit-test/tests/rrtmgp/test_rrtmgp_dry_static_energy_tendency.pf
A    test/unit-test/tests/rrtmgp/test_rrtmgp_sw_solar_var_setup.pf
- Add unit tests for RRTMGP

List all existing files that have been modified, and describe the changes:
(Helpful git command: git diff --name-status development...<your_branch_name>)

M    schemes/rrtmgp/utils/rrtmgp_dry_static_energy_tendency.F90
M    schemes/rrtmgp/utils/rrtmgp_dry_static_energy_tendency.meta
- change qrs_prime and qrl_prime to inout variables (bugfix)

M    test/unit-test/CMakeLists.txt
M    test/unit-test/tests/CMakeLists.txt
- add cmake infrastructure to see RRTMGP test directories

List all automated tests that failed, as well as an explanation for why they weren't fixed: n/a

Is this an answer-changing PR? If so, is it a new physics package, algorithm change, tuning change, etc? no

If yes to the above question, describe how this code was validated with the new/modified features:

@peverwhee peverwhee requested a review from nusbaume March 9, 2026 16:06
@peverwhee peverwhee self-assigned this Mar 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant