diff --git a/cluster-autoscaler/cloudprovider/azure/azure_util_test.go b/cluster-autoscaler/cloudprovider/azure/azure_util_test.go index 24d3b6c48fa8..50538ddc2c57 100644 --- a/cluster-autoscaler/cloudprovider/azure/azure_util_test.go +++ b/cluster-autoscaler/cloudprovider/azure/azure_util_test.go @@ -36,12 +36,6 @@ import ( "k8s.io/legacy-cloud-providers/azure/retry" ) -const ( - testAccountName = "account" - storageAccountClientErrMsg = "Server failed to authenticate the request. Make sure the value of Authorization " + - "header is formed correctly including the signature" -) - func GetTestAzureUtil(t *testing.T) *AzUtil { return &AzUtil{manager: newTestAzureManager(t)} } @@ -305,26 +299,6 @@ func TestIsAzureRequestsThrottled(t *testing.T) { } } -func TestDeleteBlob(t *testing.T) { - ctrl := gomock.NewController(t) - defer ctrl.Finish() - - azUtil := GetTestAzureUtil(t) - mockSAClient := mockstorageaccountclient.NewMockInterface(ctrl) - mockSAClient.EXPECT().ListKeys( - gomock.Any(), - azUtil.manager.config.ResourceGroup, - testAccountName).Return(storage.AccountListKeysResult{ - Keys: &[]storage.AccountKey{ - {Value: to.StringPtr("dmFsdWUK")}, - }, - }, nil) - azUtil.manager.azClient.storageAccountsClient = mockSAClient - - err := azUtil.DeleteBlob(testAccountName, "vhd", "blob") - assert.True(t, strings.Contains(err.Error(), storageAccountClientErrMsg)) -} - func TestDeleteVirtualMachine(t *testing.T) { ctrl := gomock.NewController(t) defer ctrl.Finish()