-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed for Ability to create Container Registry with zone redundancy (#…
…38588) * Fixed for Ability to create Container Registry with zone redundancy (issue#38488)
- Loading branch information
Showing
4 changed files
with
67 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
...ry/src/test/java/com/azure/resourcemanager/containerregistry/RegistryOperationsTests.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT License. | ||
|
||
package com.azure.resourcemanager.containerregistry; | ||
|
||
import com.azure.core.management.Region; | ||
import com.azure.resourcemanager.containerregistry.models.Registry; | ||
import org.junit.jupiter.api.Assertions; | ||
import org.junit.jupiter.api.Test; | ||
|
||
public class RegistryOperationsTests extends RegistryTest { | ||
|
||
@Override | ||
protected void cleanUpResources() { | ||
resourceManager.resourceGroups().beginDeleteByName(rgName); | ||
} | ||
|
||
@Test | ||
public void canCreateContainerRegisterWithZoneRedundancy() { | ||
final String acrName = generateRandomResourceName("acr", 10); | ||
Registry registry = | ||
registryManager | ||
.containerRegistries() | ||
.define(acrName) | ||
.withRegion(Region.US_EAST) | ||
.withNewResourceGroup(rgName) | ||
.withPremiumSku() | ||
.withRegistryNameAsAdminUser() | ||
.withZoneRedundancy() | ||
.create(); | ||
Assertions.assertTrue(registry.isZoneRedundancyEnabled()); | ||
} | ||
} |