mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-20 21:16:00 +02:00
add unit test and documentation for finalizers (#2509)
* add unit test and documentation for finalizers * error msg with lower case and cover sync case * try to avoid adding json-patch dependency * use Update to remove finalizer * changing status and finalizer during create * do not call Delete() twice
This commit is contained in:
@@ -2741,7 +2741,7 @@ func TestGenerateResourceRequirements(t *testing.T) {
|
||||
clusterNameLabel := "cluster-name"
|
||||
sidecarName := "postgres-exporter"
|
||||
|
||||
// enforceMinResourceLimits will be called 2 twice emitting 4 events (2x cpu, 2x memory raise)
|
||||
// enforceMinResourceLimits will be called 2 times emitting 4 events (2x cpu, 2x memory raise)
|
||||
// enforceMaxResourceRequests will be called 4 times emitting 6 events (2x cpu, 4x memory cap)
|
||||
// hence event bufferSize of 10 is required
|
||||
newEventRecorder := record.NewFakeRecorder(10)
|
||||
|
||||
Reference in New Issue
Block a user