diff --git a/test/e2e/fleetautoscaler_test.go b/test/e2e/fleetautoscaler_test.go index 9b38b901e5..0615fbf59d 100644 --- a/test/e2e/fleetautoscaler_test.go +++ b/test/e2e/fleetautoscaler_test.go @@ -116,9 +116,11 @@ func TestAutoScalerStressCreate(t *testing.T) { for i := 0; i < 30; i++ { fas := defaultFleetAutoScaler(flt) bufferSize := r.Int31n(10) + minReplicas := r.Int31n(10) + maxReplicas := r.Int31n(10) fas.Spec.Policy.Buffer.BufferSize = intstr.FromInt(int(bufferSize)) - fas.Spec.Policy.Buffer.MinReplicas = r.Int31n(10) - fas.Spec.Policy.Buffer.MaxReplicas = r.Int31n(10) + fas.Spec.Policy.Buffer.MinReplicas = minReplicas + fas.Spec.Policy.Buffer.MaxReplicas = maxReplicas valid := bufferSize > 0 && fas.Spec.Policy.Buffer.MaxReplicas > 0 && @@ -150,8 +152,8 @@ func TestAutoScalerStressCreate(t *testing.T) { assert.False(t, valid, fmt.Sprintf("FleetAutoscaler NOT created even if the parameters are valid: %d %d %d", bufferSize, - fas.Spec.Policy.Buffer.MinReplicas, - fas.Spec.Policy.Buffer.MaxReplicas)) + minReplicas, + maxReplicas)) } } }