Simplify kubeadm bump version on TestEtcdSupportedVersion

k3s-v1.15.3
Yago Nobre 2019-04-03 01:28:07 -03:00
parent 28ac3063da
commit cd605e7d14
No known key found for this signature in database
GPG Key ID: 75E01A69D4DEE54C
1 changed files with 4 additions and 9 deletions

View File

@ -160,18 +160,13 @@ func TestEtcdSupportedVersion(t *testing.T) {
expectedError: errors.New("Unsupported or unknown Kubernetes version(1.99.0)"), expectedError: errors.New("Unsupported or unknown Kubernetes version(1.99.0)"),
}, },
{ {
kubernetesVersion: "1.12.1", kubernetesVersion: MinimumControlPlaneVersion.WithPatch(1).String(),
expectedVersion: version.MustParseSemantic("3.2.24"), expectedVersion: version.MustParseSemantic(SupportedEtcdVersion[uint8(MinimumControlPlaneVersion.Minor())]),
expectedError: nil, expectedError: nil,
}, },
{ {
kubernetesVersion: "1.13.1", kubernetesVersion: CurrentKubernetesVersion.String(),
expectedVersion: version.MustParseSemantic("3.2.24"), expectedVersion: version.MustParseSemantic(SupportedEtcdVersion[uint8(CurrentKubernetesVersion.Minor())]),
expectedError: nil,
},
{
kubernetesVersion: "1.14.0",
expectedVersion: version.MustParseSemantic("3.3.10"),
expectedError: nil, expectedError: nil,
}, },
} }