NCAR / ccpp-framework

Common Community Physics Package (CCPP)
http://www.dtcenter.org/community-code/common-community-physics-package-ccpp/
Other
26 stars 64 forks source link

Enhanced/Expanded Testing #595

Open dustinswales opened 1 month ago

dustinswales commented 1 month ago

Description

Testing in the Framework is achieved via ~large system tests, not by modular unit tests. The contents of these system tests is diverse, and has expanded over time, so it's not clear what/where/how things are being tested. Unit testing is not practical for most of the tests we need, so how do we design a testing harness that is manageable and extendible.

Solutions

It was discussed that at the very least we should document what is being tested in our existing systems tests, and to continue to do so going forward. Maybe this is enough? Ultimately, Capgen will be embedded within several modeling systems, providing much more coverage testing than our system tests, but relying on application testing is not a great idea IMO. Thoguhts?

dustinswales commented 1 month ago

A possible resource/option: unittest.mock (https://docs.python.org/3/library/unittest.mock.html)

climbfuji commented 1 month ago

@mwaxmonsky has experience with the unittest mock library :-)