volume/mounts: minor linting issues, touch-ups, and improve test-coverage#48776
Merged
thaJeztah merged 6 commits intomoby:masterfrom Oct 28, 2024
Merged
volume/mounts: minor linting issues, touch-ups, and improve test-coverage#48776thaJeztah merged 6 commits intomoby:masterfrom
thaJeztah merged 6 commits intomoby:masterfrom
Conversation
These parsers can be compiled and used cross-platform, but follow platform-
specific semantics. Remove the use of runtime.GOOS, as it would result in
confusing errors ("linux does not support tmpfs").
Signed-off-by: Sebastiaan van Stijn <[email protected]>
These errors used a backtick, which is not commonly used in our errors. Change them to use single quotes instead. Signed-off-by: Sebastiaan van Stijn <[email protected]>
Signed-off-by: Sebastiaan van Stijn <[email protected]>
ParseMountRaw returns a nil value on error, so there's nothing to check other than it not returning a value. Signed-off-by: Sebastiaan van Stijn <[email protected]>
Update the tests to have a match for the actual error string returned. Signed-off-by: Sebastiaan van Stijn <[email protected]>
Make sure we're asserting the right fields to be propagated, as there are some fields that shadow top-level fields (by design). Signed-off-by: Sebastiaan van Stijn <[email protected]>
f41b242 to
3188079
Compare
vvoland
approved these changes
Oct 28, 2024
Member
Author
|
Thx! Let me bring this one in; there's more I want to look at in this package, as there's some gnarly bits, but having more coverage helps verifying changes. |
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.
volume/mounts: windowsParser.ConvertTmpfsOptions don't use runtime.GOOS
These parsers can be compiled and used cross-platform, but follow platform-
specific semantics. Remove the use of runtime.GOOS, as it would result in
confusing errors ("linux does not support tmpfs").
volume/mounts: windowsParser.ConvertTmpfsOptions don't use runtime.GOOS
volumes/mounts: remove backticks from errors
These errors used a backtick, which is not commonly used in our errors.
Change them to use single quotes instead.
volumes/mounts: remove backticks from test logs
volumes/mounts: don't set "expected" values for fail cases
ParseMountRaw returns a nil value on error, so there's nothing to
check other than it not returning a value.
volumes/mounts: test the actual error returned
Update the tests to have a match for the actual error string returned.
volumes/mounts: test the actual MountConfig returned
Make sure we're asserting the right fields to be propagated, as there
are some fields that shadow top-level fields (by design).
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)