-
Notifications
You must be signed in to change notification settings - Fork 557
Reenable AzureFile tests for Windows on K8s 1.11.1, resolves #3439 #3496
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3496 +/- ##
==========================================
+ Coverage 55.47% 55.89% +0.41%
==========================================
Files 105 105
Lines 16004 15943 -61
==========================================
+ Hits 8879 8911 +32
+ Misses 6375 6282 -93
Partials 750 750 |
The version check isn't working as expected. Will add unit tests next to figure it out. I would expect this test case to be skipped on v1.11.0 |
3c62d49
to
b5c5474
Compare
@CecileRobertMichon thanks for helping me figure out the right way to check versions. Can you do a review? |
pkg/api/common/versions.go
Outdated
@@ -351,6 +351,13 @@ func IsKubernetesVersionGe(actualVersion, version string) bool { | |||
return v1.GE(v2) | |||
} | |||
|
|||
// IsKubernetesVersionEq returns true if actualVersion is equal to version | |||
func IsKubernetesVersionEq(actualVersion, version string) bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not just compare the strings for this?
If you decide to keep it, it'd be an easy unit test to add in versions_test.go --> you already did that nevermind!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Originally I was hoping the semantic versioning library could handle some cases like "1.11" == "1.11.0" . It doesn't handle that case so I should probably keep it simple and remove it.
// Failure in 1.11+ - https://github.com/kubernetes/kubernetes/issues/65845 | ||
Skip("Kubernetes 1.11 has a known issue creating Azure PersistentVolumeClaims") | ||
} else if common.IsKubernetesVersionGe(eng.ClusterDefinition.ContainerService.Properties.OrchestratorProfile.OrchestratorVersion, "1.8") { | ||
if common.IsKubernetesVersionEq(eng.ExpandedDefinition.Properties.OrchestratorProfile.OrchestratorVersion, "1.11.0") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could be if eng.ExpandedDefinition.Properties.OrchestratorProfile.OrchestratorVersion == "1.11.0" {
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed - I wasn't sure if OrchestratorVersion could be "1.11", but it's showing up as "1.11.0". The string comparison is sufficient here so I'll keep it simple
b5c5474
to
ccca36f
Compare
Simplifying to ==
ccca36f
to
50534ba
Compare
@CecileRobertMichon thanks. Simplified per feedback and rebased. |
if eng.ExpandedDefinition.Properties.OrchestratorProfile.OrchestratorVersion == "1.11.0" { | ||
// Failure in 1.11.0 - https://github.com/kubernetes/kubernetes/issues/65845, fixed in 1.11.1 | ||
Skip("Kubernetes 1.11.0 has a known issue creating Azure PersistentVolumeClaims") | ||
} else if common.IsKubernetesVersionGe(eng.ExpandedDefinition.Properties.OrchestratorProfile.OrchestratorVersion, "1.8") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure "1.8" is a valid version, I think you need "1.8.0"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yes you're right.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: CecileRobertMichon, PatrickLang The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
* 'master' of https://github.com/Azure/acs-engine: (59 commits) Docs: Update user guide list to include Windows, update description of clusters (Azure#3473) update to Azure CNI v1.0.10 (Azure#3551) Adding 'make dev' equivalent for Windows (Azure#3471) print out ubuntu ver in e2e (Azure#3555) fix an issue where networkPlugin was not defined correctly when using calico or cilium (Azure#3271) Bump ginkgo to a tagged release (Azure#3554) Reenable AzureFile tests for Windows on K8s 1.11.1, resolves Azure#3439 (Azure#3496) removing rbac error checking from merge fn (Azure#3530) Change dns healthcheck to look at external domain (Azure#3282) DOCUMENTATION: Fix Documented Default Value for clusterSubnet (Azure#3474) Document required manual calico 2.6.3 -> calico 3.1.1 upgrade when upgrading from < 0.17.0-provisioned clusters (Azure#3208) revert --image-pull-policy=IfNotPresent for win (Azure#3553) --image-pull-policy=IfNotPresent for kubectl run commands (Azure#3552) Kubernetes: --max-pods=30 should be Azure CNI-only (Azure#3543) disable Azure CNI network monitor addon default (Azure#3550) only do az vm list for k8s (Azure#3540) Retire Swarm E2E for PR test coverage (Azure#3539) retire Azure CDN for container image repository proxying (Azure#3535) removed datadisk to allow scale after upgrade (Azure#3482) Pump k8s-azure-kms version (Azure#3531) ...
* master: (59 commits) Docs: Update user guide list to include Windows, update description of clusters (Azure#3473) update to Azure CNI v1.0.10 (Azure#3551) Adding 'make dev' equivalent for Windows (Azure#3471) print out ubuntu ver in e2e (Azure#3555) fix an issue where networkPlugin was not defined correctly when using calico or cilium (Azure#3271) Bump ginkgo to a tagged release (Azure#3554) Reenable AzureFile tests for Windows on K8s 1.11.1, resolves Azure#3439 (Azure#3496) removing rbac error checking from merge fn (Azure#3530) Change dns healthcheck to look at external domain (Azure#3282) DOCUMENTATION: Fix Documented Default Value for clusterSubnet (Azure#3474) Document required manual calico 2.6.3 -> calico 3.1.1 upgrade when upgrading from < 0.17.0-provisioned clusters (Azure#3208) revert --image-pull-policy=IfNotPresent for win (Azure#3553) --image-pull-policy=IfNotPresent for kubectl run commands (Azure#3552) Kubernetes: --max-pods=30 should be Azure CNI-only (Azure#3543) disable Azure CNI network monitor addon default (Azure#3550) only do az vm list for k8s (Azure#3540) Retire Swarm E2E for PR test coverage (Azure#3539) retire Azure CDN for container image repository proxying (Azure#3535) removed datadisk to allow scale after upgrade (Azure#3482) Pump k8s-azure-kms version (Azure#3531) ...
Kubernetes v1.11.1 is out, including the azurefiles fixes. This fixes the skipped test case to only skip v1.11.0 and run on other versions.