Skip to content

Commit f9f3620

Browse files
authored
Update service bus to enable live testing in sovereign clouds for multiple services (Azure#20248)
1 parent 4faa7a4 commit f9f3620

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

sdk/servicebus/service-bus/test/internal/serviceBusClient.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ describe("ServiceBusClient live tests", () => {
377377

378378
const env = getEnvVars();
379379
const serviceBusEndpoint = (env.SERVICEBUS_CONNECTION_STRING.match(
380-
"Endpoint=sb://((.*).servicebus.windows.net)"
380+
"Endpoint=sb://((.*).servicebus.(windows.net|usgovcloudapi.net|chinacloudapi.cn))"
381381
) || "")[1];
382382

383383
/**

sdk/servicebus/service-bus/test/public/atomManagement.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,8 @@ versionsToTest(serviceApiVersions, {}, (serviceVersion) => {
403403
);
404404
should.equal(
405405
(await serviceBusAdministrationClient.getNamespaceProperties()).name,
406-
(host.match("(.*).servicebus.windows.net") || [])[1],
406+
(host.match("(.*).servicebus.(windows.net|usgovcloudapi.net|chinacloudapi.cn)") ||
407+
[])[1],
407408
"Unexpected namespace name in the getNamespaceProperties response"
408409
);
409410
await serviceBusAdministrationClient.deleteQueue(managementQueue1);
@@ -426,7 +427,7 @@ versionsToTest(serviceApiVersions, {}, (serviceVersion) => {
426427

427428
should.equal(
428429
(await serviceBusAdministrationClient.getNamespaceProperties()).name,
429-
(host.match("(.*).servicebus.windows.net") || [])[1],
430+
(host.match("(.*).servicebus.(windows.net|usgovcloudapi.net|chinacloudapi.cn)") || [])[1],
430431
"Unexpected namespace name in the getNamespaceProperties response"
431432
);
432433
});

sdk/servicebus/service-bus/tests.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@ stages:
77
ServiceDirectory: servicebus
88
TimeoutInMinutes: 180
99
Clouds: 'Public,Canary'
10+
SupportedClouds: 'Public,UsGov,China'
1011
EnvVars:
11-
AZURE_CLIENT_ID: $(aad-azure-sdk-test-client-id)
12-
AZURE_TENANT_ID: $(aad-azure-sdk-test-tenant-id)
13-
AZURE_CLIENT_SECRET: $(aad-azure-sdk-test-client-secret)
14-
AZURE_SUBSCRIPTION_ID: $(test-subscription-id)
12+
AZURE_CLIENT_ID: $(SERVICEBUS_CLIENT_ID)
13+
AZURE_TENANT_ID: $(SERVICEBUS_TENANT_ID)
14+
AZURE_CLIENT_SECRET: $(SERVICEBUS_CLIENT_SECRET)
15+
AZURE_SUBSCRIPTION_ID: $(SERVICEBUS_SUBSCRIPTION_ID)

0 commit comments

Comments
 (0)