Removing old v3 unit tests#2766
Open
erikvansebille wants to merge 15 commits into
Open
Conversation
As most tests are now in test_interpolation
As all these tests are related to old FieldSet creation API
Only tests old API for interpolators
VeckoTheGecko
left a comment
Contributor
There was a problem hiding this comment.
some prelim feedback
Contributor
There was a problem hiding this comment.
I think this test file is worth keeping.
_format_list_items_multilineexists insrc/parcels/_reprs.pydeprecatedanddeprecated_made_privateexist insrc/parcels/_decorators.py
Perhaps two separate files test_decorators.py and test_repr_utils.py (and maybe a rename of src/parcels/_reprs.py to src/parcels/_repr_utils.py)
Comment on lines
+206
to
+218
| def test_multi_kernel_duplicate_varnames(fieldset): | ||
| # Testing for merging of two Kernels with the same variable declared | ||
| def Kernel1(particles, fieldset): # pragma: no cover | ||
| add_lon = 0.1 | ||
| particles.dx += add_lon | ||
|
|
||
| def Kernel2(particles, fieldset): # pragma: no cover | ||
| add_lon = -0.3 | ||
| particles.dx += add_lon | ||
|
|
||
| pset = ParticleSet(fieldset, x=[0.5], y=[0.5]) | ||
| pset.execute([Kernel1, Kernel2], runtime=1.0, dt=1.0) | ||
| np.testing.assert_allclose(pset.x, 0.3, rtol=1e-5) |
Contributor
There was a problem hiding this comment.
I'm not quite sure what this is testing - we don't have the code-generator anymore nor merge kernels internally (this test was introduced in cd6feea ).
Perhaps just remove?
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.
Description
This PR moves some of the last relevant tests from v3 over to the new v4 test suite, and removes the other irrelevant or already-copied tests. It also updates the interpolation_regression test
The only file that remains is tests-v3/test_reprs.py; @VeckoTheGecko, can you confirm if this test file can also go?
Checklist
mainfor normal development,v3-supportfor v3 support)AI Disclosure
None