Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
10f6ad0
Change the accessbility to virtual for Resource.Id
Mar 24, 2021
ccc17c7
merge from usptream
Apr 5, 2021
5060f5c
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash Apr 12, 2021
9a9a651
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash Apr 21, 2021
7764cb5
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Apr 23, 2021
832483a
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Apr 28, 2021
3066cd2
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
May 6, 2021
9597dc7
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
May 6, 2021
86547b0
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash May 10, 2021
4fa650c
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash May 10, 2021
6f858c5
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash May 17, 2021
fb80156
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash May 25, 2021
737171b
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash Jun 2, 2021
4f1408d
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Jun 4, 2021
c5d5790
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash Jun 7, 2021
0bcb9e4
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Jun 7, 2021
2a78d80
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Jun 11, 2021
23eca40
Merge branch 'mgmt-track2' of https://github.com/AME-Redmond/azure-sd…
m-nash Jun 16, 2021
2bddb0e
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
m-nash Jun 16, 2021
1405a35
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Jun 17, 2021
b874653
Merge branch 'feature/mgmt-track2' of https://github.com/Azure/azure-…
Jun 18, 2021
fe35fa0
Add ResourceGroupsRestOperations tests
Jun 19, 2021
8f94cc7
Override DoesExist() in ResourceGroupContainer class
Jun 22, 2021
0325ee0
Address comment
Jun 22, 2021
29cd85d
Update tests records
Jun 22, 2021
4b4f38e
Update records
Jun 22, 2021
39560d6
Remove DoesExist() tests
Jun 23, 2021
9f56fb8
Add DoesExist() tests back
Jun 23, 2021
d436257
Update test records
Jun 23, 2021
924c406
Update records
Jun 23, 2021
438db29
Add try catch
Jun 23, 2021
ef15091
Revert some records
Jun 23, 2021
268f413
Revert some records
Jun 23, 2021
78f14b5
Remove duplicate test for DoesExist()
Jun 23, 2021
b78b2a1
Revert some records
Jun 24, 2021
1e3b2c9
Update StartDeleteRg() record
Jun 24, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,5 @@ public async Task TryGetTest()
result = await _container.TryGetAsync("FakeName");
Assert.IsNull(result);
}

[TestCase]
[RecordedTest]
[SyncOnly]
public void DoesExistTest()
{
Assert.IsTrue(_container.DoesExist(_rgName));
Assert.IsFalse(_container.DoesExist("FakeName"));
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,20 @@ public async Task Get()
Assert.AreEqual(rg.Data.Location, rg2.Data.Location);
Assert.AreEqual(rg.Data.ManagedBy, rg2.Data.ManagedBy);
Assert.AreEqual(rg.Data.Tags, rg2.Data.Tags);

Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await Client.DefaultSubscription.GetResourceGroups().GetAsync(null));
}

[TestCase]
[RecordedTest]
public async Task DoesExist()
{
var rgName = Recording.GenerateAssetName("testRg-");
ResourceGroup rg = await Client.DefaultSubscription.GetResourceGroups().Construct(LocationData.WestUS2).CreateOrUpdateAsync(rgName);
Assert.IsTrue(await Client.DefaultSubscription.GetResourceGroups().DoesExistAsync(rgName));
Assert.IsFalse(await Client.DefaultSubscription.GetResourceGroups().DoesExistAsync(rgName + "1"));

Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await Client.DefaultSubscription.GetResourceGroups().DoesExistAsync(null));
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ public async Task StartDeleteRg()
await deleteOp.UpdateStatusAsync();
await deleteOp.WaitForCompletionResponseAsync();
await deleteOp.WaitForCompletionResponseAsync(TimeSpan.FromSeconds(2));

var rgOp2 = await Client.DefaultSubscription.GetResourceGroups().Construct(LocationData.WestUS2).StartCreateOrUpdateAsync(Recording.GenerateAssetName("testrg"));
ResourceGroup rg2 = await rgOp.WaitForCompletionAsync();
rg2.Id.Name = null;
Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await rg2.StartDeleteAsync());
}

[TestCase]
Expand All @@ -61,6 +66,9 @@ public async Task Get()
Assert.AreEqual(rg1.Data.Location, rg2.Data.Location);
Assert.AreEqual(rg1.Data.ManagedBy, rg2.Data.ManagedBy);
Assert.AreEqual(rg1.Data.Tags, rg2.Data.Tags);

rg1.Id.Name = null;
Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await rg1.GetAsync());
}

[TestCase]
Expand All @@ -83,6 +91,9 @@ public async Task Update()
Assert.AreEqual(rg1.Data.Tags, rg2.Data.Tags);

Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await rg1.UpdateAsync(null));

rg1.Id.Name = null;
Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await rg1.UpdateAsync(parameters));
}

[TestCase]
Expand All @@ -100,6 +111,9 @@ public async Task StartExportTemplate()
var expOp = await rg.StartExportTemplateAsync(null);
_ = await expOp.WaitForCompletionAsync();
});

rg.Id.Name = null;
Assert.ThrowsAsync<ArgumentNullException>(async () => _ = await rg.StartExportTemplateAsync(parameters));
}

[TestCase]
Expand Down

This file was deleted.

Loading