Skip to content

Commit 8db55a4

Browse files
authored
Add another error code to the list of unregistered RP errors (Azure#21606)
1 parent 9519990 commit 8db55a4

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

sdk/azcore/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313

1414
### Bugs Fixed
1515

16+
* Fixed an issue that could cause some ARM RPs to not be automatically registered.
17+
1618
### Other Changes
1719

1820
## 1.8.0-beta.3 (2023-09-07)

sdk/azcore/arm/runtime/policy_register_rp.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ var unregisteredRPCodes = []string{
176176
"MissingSubscriptionRegistration",
177177
"MissingRegistrationForResourceProvider",
178178
"Subscription Not Registered",
179+
"SubscriptionNotRegistered",
179180
}
180181

181182
func isUnregisteredRPCode(errorCode string) bool {

sdk/azcore/arm/runtime/policy_register_rp_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,7 @@ func TestRPRegistrationPolicyEnvironmentsInSubExceeded(t *testing.T) {
414414

415415
func TestIsUnregisteredRPCode(t *testing.T) {
416416
require.True(t, isUnregisteredRPCode("Subscription Not Registered"))
417+
require.True(t, isUnregisteredRPCode("SubscriptionNotRegistered"))
417418
require.False(t, isUnregisteredRPCode("Your subscription isn't registered"))
418419
}
419420

0 commit comments

Comments
 (0)