azure_rm_storageaccount_info: Fix list_all method (#64321)

The 'azure_rm_storageaccount_info' module was calling the storage client
'list_by_resource_group()' method rather than the 'list()' one, leading
to callers not being able to fetch all the storage accounts of their
subscription.

Issue: #64319

Testing Done: was successfully able to call the module and retrieve
all the storage accounts in the subscription without having to
specify a resource group.
This commit is contained in:
mmallet 2019-11-27 08:53:51 +01:00 committed by Zim Kalinowski
parent 4b240a5d74
commit 7c65ad11e2

View file

@ -435,7 +435,7 @@ class AzureRMStorageAccountInfo(AzureRMModuleBase):
def list_all(self):
self.log('List all items')
try:
response = self.storage_client.storage_accounts.list_by_resource_group(self.resource_group)
response = self.storage_client.storage_accounts.list()
except Exception as exc:
self.fail("Error listing all items - {0}".format(str(exc)))