Add pio_reader Fortran unit tests#403
Merged
Merged
Conversation
mwaxmonsky
approved these changes
Jul 9, 2025
mwaxmonsky
left a comment
Collaborator
There was a problem hiding this comment.
Looks great @nusbaume! Found two unused mpi_ierr locals left over but otherwise, no issues here! Thanks for tackling this one!
peverwhee
approved these changes
Jul 9, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tag name (required for release branches):
Originator(s): @mwaxmonsky @nusbaume
Description (include the issue title, and the keyword ['closes', 'fixes', 'resolves'] followed by the issue number):
This PR introduces pFUnit Fortran unit tests for the
pio_readerimplementation of theccpp_io_readerabstract class that is used in CAM-SIMA, which should now run automatically with any PR to CAM-SIMA as part of the Fortran unit tests Github Action.Note that although several tests are added by this PR, the code coverage is not complete, as several of the edge cases require specialized NetCDF files that will need to be created. Github issue #404 can be used to keep track of this.
Describe any changes made to build system:
A src/physics/utils/CMakeLists.txt
M test/unit/fortran/CMakeLists.txt
A test/unit/fortran/ccpp_framework_stub/CMakeLists.txt
A test/unit/fortran/cmake/FindNetCDF.cmake
A test/unit/fortran/cmake/FindPIO.cmake
A test/unit/fortran/mock_routines/CMakeLists.txt
A test/unit/fortran/src/pio_reader/CMakeLists.tx
Describe any changes made to the namelist: N/A
List any changes to the defaults for the input datasets (e.g. boundary datasets): N/A
List all files eliminated and why: N/A
List all files added and what they do:
A test/unit/fortran/ccpp_framework_stub/ccpp_kinds.F90
A test/unit/fortran/mock_routines/cam_pio_utils.F90
A test/unit/fortran/src/pio_reader/test_pio_reader.pf
List all existing files that have been modified, and describe the changes:
(Helpful git command:
git diff --name-status development...<your_branch_name>)M .github/workflows/fortran_unit_tests.yml
M .gitignore
M src/physics/utils/pio_reader.F90
M src/utils/cam_pio_utils.F90
If there are new failures (compared to the
test/existing-test-failures.txtfile),have them OK'd by the gatekeeper, note them here, and add them to the file.
If there are baseline differences, include the test and the reason for the
diff. What is the nature of the change? Roundoff?
derecho/intel/aux_sima: ALL PASS
derecho/gnu/aux_sima: ALL PASS
If this changes climate describe any run(s) done to evaluate the new
climate in enough detail that it(they) could be reproduced:
CAM-SIMA date used for the baseline comparison tests if different than latest: