Skip to content

Commit

Permalink
Merge branch 'main' into tallaxes/test-suites/termination
Browse files Browse the repository at this point in the history
  • Loading branch information
tallaxes authored Jan 14, 2025
2 parents 1827419 + 93d641c commit 6d3a6e7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/pkg/environment/common/expectations.go
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,12 @@ func (env *Environment) EventuallyExpectKarpenterRestarted() {
GinkgoHelper()
By("rolling out the new karpenter deployment")
env.EventuallyExpectRollout("karpenter", "kube-system")
env.ExpectKarpenterLeaseOwnerChanged()

if !lo.ContainsBy(env.ExpectSettings(), func(v corev1.EnvVar) bool {
return v.Name == "DISABLE_LEADER_ELECTION" && v.Value == "true"
}) {
env.ExpectKarpenterLeaseOwnerChanged()
}
}

func (env *Environment) ExpectKarpenterLeaseOwnerChanged() {
Expand Down

0 comments on commit 6d3a6e7

Please sign in to comment.