@@ -351,7 +351,7 @@ func TestEtcdCreateDeploymentRollback(t *testing.T) {
351
351
if _ , err := storage .Deployment .Create (ctx , validNewDeployment (), rest .ValidateAllObjectFunc , & metav1.CreateOptions {}); err != nil {
352
352
t .Fatalf ("%s: unexpected error: %v" , k , err )
353
353
}
354
- rollbackRespStatus , err := rollbackStorage .Create (ctx , & test .rollback , rest .ValidateAllObjectFunc , & metav1.CreateOptions {})
354
+ rollbackRespStatus , err := rollbackStorage .Create (ctx , test . rollback . Name , & test .rollback , rest .ValidateAllObjectFunc , & metav1.CreateOptions {})
355
355
if ! test .errOK (err ) {
356
356
t .Errorf ("%s: unexpected error: %v" , k , err )
357
357
} else if err == nil {
@@ -392,7 +392,7 @@ func TestCreateDeploymentRollbackValidation(t *testing.T) {
392
392
393
393
validationError := fmt .Errorf ("admission deny" )
394
394
alwaysDenyValidationFunc := func (obj runtime.Object ) error { return validationError }
395
- _ , err := rollbackStorage .Create (ctx , & rollback , alwaysDenyValidationFunc , & metav1.CreateOptions {})
395
+ _ , err := rollbackStorage .Create (ctx , rollback . Name , & rollback , alwaysDenyValidationFunc , & metav1.CreateOptions {})
396
396
397
397
if err == nil || validationError != err {
398
398
t .Errorf ("expected: %v, got: %v" , validationError , err )
@@ -411,7 +411,7 @@ func TestEtcdCreateDeploymentRollbackNoDeployment(t *testing.T) {
411
411
rollbackStorage := storage .Rollback
412
412
ctx := genericapirequest .WithNamespace (genericapirequest .NewContext (), namespace )
413
413
414
- _ , err := rollbackStorage .Create (ctx , & apps.DeploymentRollback {
414
+ _ , err := rollbackStorage .Create (ctx , name , & apps.DeploymentRollback {
415
415
Name : name ,
416
416
UpdatedAnnotations : map [string ]string {},
417
417
RollbackTo : apps.RollbackConfig {Revision : 1 },
0 commit comments