Skip to content

Commit 7a4b271

Browse files
update testcase
1 parent 11b648c commit 7a4b271

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/AzureAppConfigurationImpl.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ export class AzureAppConfigurationImpl implements AzureAppConfiguration {
340340
*/
341341
onRefresh(listener: () => any, thisArg?: any): Disposable {
342342
if (!this.#refreshEnabled && !this.#featureFlagRefreshEnabled && !this.#secretRefreshEnabled) {
343-
throw new InvalidOperationError("Refresh is not enabled for key-values, key vault secrets or feature flags.");
343+
throw new InvalidOperationError("Refresh is not enabled for key-values, feature flags or Key Vault secrets.");
344344
}
345345

346346
const boundedListener = listener.bind(thisArg);

test/refresh.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ describe("dynamic refresh", function () {
5555
const connectionString = createMockedConnectionString();
5656
const settings = await load(connectionString);
5757
const refreshCall = settings.refresh();
58-
return expect(refreshCall).eventually.rejectedWith("Refresh is not enabled for key-values, key vault secrets or feature flags.");
58+
return expect(refreshCall).eventually.rejectedWith("Refresh is not enabled for key-values, feature flags or Key Vault secrets.");
5959
});
6060

6161
it("should not allow refresh interval less than 1 second", async () => {
@@ -117,7 +117,7 @@ describe("dynamic refresh", function () {
117117
it("should throw error when calling onRefresh when refresh is not enabled", async () => {
118118
const connectionString = createMockedConnectionString();
119119
const settings = await load(connectionString);
120-
expect(() => settings.onRefresh(() => { })).throws("Refresh is not enabled for key-values, key vault secrets or feature flags.");
120+
expect(() => settings.onRefresh(() => { })).throws("Refresh is not enabled for key-values, feature flags or Key Vault secrets.");
121121
});
122122

123123
it("should only update values after refreshInterval", async () => {

0 commit comments

Comments
 (0)