atmtools / typhon

Tools for atmospheric research
http://www.radiativetransfer.org/
MIT License
58 stars 33 forks source link

Update and Add Tests for FileSet, Collocator and SPAREICE #216

Open JohnMrziglod opened 6 years ago

JohnMrziglod commented 6 years ago

Owing to the recent development of these classes, there are just a few tests working and most of them are obsolete. Hence, they need a review and many tests must be added. This issue acts as a ToDo list for tests and will be updated in future.

FileSet and FileHandler

Collocator, Collocations and related functions

SPAREICE

JohnMrziglod commented 6 years ago

@olemke and @lkluft , I would like to test the file handler of MHS, etc. Do you know a good way of doing this? For instance, is it possible to ship an original MHS file as test case?

olemke commented 6 years ago

Since it's likely that other similar test files need to be added in the future and they're of considerable size, it is not feasible to have them inside the typhon repository itself. After discussion with @lkluft, we came to the conclusion that we should have a separate typhon-testfiles repository which can be optionally checked out alongside typhon. If this repository is present (location could also be set by the user via an environment variable TYPHONTESTFILES) the tests that require these additional files are executed and otherwise skipped.

JohnMrziglod commented 6 years ago

I like this idea of separation. But wouldn't it be more consistent to move all test scripts and files (i.e. typhon/tests) to that repository?

olemke commented 6 years ago

The tests should always be part of the main package. Tests that need larger input files to run are an exception. Usually tests don't need any input files at all. Not being able to run tests without checking out a second package would be very inconvenient. Having them separate from the main typhon package would also require two pull requests to add code and tests. We already get complaints that doing one pull request to commit code is too much of a hassle, requiring two would be a death sentence for test contributions.