示例#1
0
 public async Task TestSetUp()
 {
     if (Mode == RecordedTestMode.Record || Mode == RecordedTestMode.Playback)
     {
         Initialize();
         string groupName = Recording.GenerateAssetName(ResourceGroupPrefix);
         ResGroup = await(await ArmClient.GetDefaultSubscriptionAsync().Result.GetResourceGroups().CreateOrUpdateAsync(groupName, new ResourceGroupData(Location))).WaitForCompletionAsync();
         string configurationStoreName = Recording.GenerateAssetName("testapp-");
         ConfigurationStoreData configurationStoreData = new ConfigurationStoreData(Location, new Models.Sku("Standard"))
         {
             PublicNetworkAccess = PublicNetworkAccess.Disabled
         };
         ConfigStore  = (await ResGroup.GetConfigurationStores().CreateOrUpdateAsync(true, configurationStoreName, configurationStoreData)).Value;
         LinkResource = await ConfigStore.GetPrivateLinkResources().GetAsync("configurationStores");
     }
 }