@@ -15,7 +15,7 @@ import { delay } from "@azure/core-util";
15
15
import { createLiveCredential , createTestCredential } from "@azure-tools/test-credential" ;
16
16
import { afterAll , afterEach , beforeAll , describe , it } from "vitest" ;
17
17
import { assert , should } from "../public/utils/chai.js" ;
18
- import { getConnectionStringPremium } from "../utils/injectables.js" ;
18
+ import { getFullyQualifiedNamespacePremium } from "../utils/injectables.js" ;
19
19
20
20
describe ( "Send Batch" , ( ) => {
21
21
let sender : ServiceBusSender ;
@@ -514,15 +514,12 @@ describe("Send Batch", () => {
514
514
} ) ;
515
515
} ) ;
516
516
517
- const premiumNamespaceConnectionString = getConnectionStringPremium ( ) ;
518
- describe . runIf ( premiumNamespaceConnectionString ) ( "Premium namespaces - Sending" , ( ) => {
517
+ describe ( "Premium namespaces - Sending" , ( ) => {
518
+ const premiumNamespaceFQNS = getFullyQualifiedNamespacePremium ( ) ;
519
519
let atomClient : ServiceBusAdministrationClient ;
520
520
521
521
beforeAll ( function ( ) {
522
- atomClient = new ServiceBusAdministrationClient (
523
- premiumNamespaceConnectionString ! ,
524
- createLiveCredential ( ) ,
525
- ) ;
522
+ atomClient = new ServiceBusAdministrationClient ( premiumNamespaceFQNS , createLiveCredential ( ) ) ;
526
523
} ) ;
527
524
let sender : ServiceBusSender ;
528
525
let serviceBusClient : ServiceBusClient ;
@@ -539,21 +536,15 @@ describe.runIf(premiumNamespaceConnectionString)("Premium namespaces - Sending",
539
536
: TestClientType . UnpartitionedTopicWithSessions ;
540
537
541
538
beforeAll ( ( ) => {
542
- serviceBusClient = new ServiceBusClient (
543
- premiumNamespaceConnectionString ! ,
544
- createLiveCredential ( ) ,
545
- ) ;
539
+ serviceBusClient = new ServiceBusClient ( premiumNamespaceFQNS , createLiveCredential ( ) ) ;
546
540
} ) ;
547
541
548
542
afterAll ( async ( ) => {
549
543
await serviceBusClient . close ( ) ;
550
544
} ) ;
551
545
552
546
async function beforeEachTest ( entityType : TestClientType ) : Promise < void > {
553
- atomClient = new ServiceBusAdministrationClient (
554
- premiumNamespaceConnectionString ! ,
555
- createTestCredential ( ) ,
556
- ) ;
547
+ atomClient = new ServiceBusAdministrationClient ( premiumNamespaceFQNS , createTestCredential ( ) ) ;
557
548
withSessions = entityType . includes ( "WithSessions" ) ;
558
549
const randomSeed = Math . ceil ( Math . random ( ) * 10000 + 1000 ) ;
559
550
const isQueue = entityType . includes ( "Queue" ) ;
0 commit comments