Skip to content

Commit

Permalink
Re-add the event recorder in the release test
Browse files Browse the repository at this point in the history
Prior having a mock recorder would cause panics since the lock
would be set to nil on update failures. Now the recorder will
use the cached lock

Kubernetes-commit: 7622eb6a89cb7f7d62a5c7d1d845959fdc8e268b
  • Loading branch information
dprotaso authored and k8s-publishing-bot committed Oct 28, 2020
1 parent 478748c commit a7c6cd2
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tools/leaderelection/leaderelection_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1097,9 +1097,8 @@ func testReleaseOnCancellation(t *testing.T, objectType string) {
)

resourceLockConfig := rl.ResourceLockConfig{
Identity: "baz",
// TODO - uncomment this to introduce errors
// EventRecorder: &record.FakeRecorder{},
Identity: "baz",
EventRecorder: &record.FakeRecorder{},
}
c := &fake.Clientset{}

Expand Down

0 comments on commit a7c6cd2

Please sign in to comment.