nat: assorted test cleanups and improvements#129
Merged
thaJeztah merged 4 commits intodocker:masterfrom May 29, 2025
Merged
Conversation
robmry
approved these changes
May 29, 2025
| doc: "zero range", | ||
| input: "0-0", | ||
| }, | ||
| // invalid cases |
Contributor
There was a problem hiding this comment.
Not important, but the original tests had "8000-a" and "8000-30a" ... maybe trying to catch the parser reading the "30" and ignoring the "a" - but that'd still be an invalid range. So, could add "8000-8000a"?
Member
Author
There was a problem hiding this comment.
Ah, yes, can do; let me add that.
Some of those possibly also originated from my PHP days where "looks numeric" would sometimes be happily converted (hex values etc) 😂
Member
Author
There was a problem hiding this comment.
Added cases for those, and adjusted 8000/9000 to be less ambiguous on "what's wrong"
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
ParsePortRangeToInt is a shallow wrapper around ParsePortRange, except for returning int's, and accepting empty values. Other cases are covered by TestParsePortRange. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
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.
see individual commits for details
- A picture of a cute animal (not mandatory but encouraged)