Skip to content

Commit

Permalink
test(version): fix TestCheckVersionString test on releasing software
Browse files Browse the repository at this point in the history
  • Loading branch information
themantre committed Aug 1, 2024
1 parent ec87b58 commit 2f30e39
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions version/version_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,10 @@ func TestVersionComparison(t *testing.T) {
// TestCheckVersionString checks if the current version string is valid and parsable.
func TestCheckVersionString(t *testing.T) {
curVer := version.NodeVersion
parsedVer, err := version.ParseVersion(curVer.StringWithAlias())
parsedVer, err := version.ParseVersion(curVer.String())
require.NoError(t, err)
assert.Equal(t, curVer, parsedVer)
assert.Equal(t, curVer.Major, parsedVer.Major)
assert.Equal(t, curVer.Minor, parsedVer.Minor)
assert.Equal(t, curVer.Patch, parsedVer.Patch)
assert.Equal(t, curVer.Meta, parsedVer.Meta)
}

0 comments on commit 2f30e39

Please sign in to comment.