Skip to content

Commit 0dddf37

Browse files
fixup! feat: support extending the user configuration
1 parent b334c33 commit 0dddf37

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

packages/wrangler/src/__tests__/configuration.test.ts

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -169,11 +169,18 @@ describe("readConfig()", () => {
169169
unexpected_property: true,
170170
} as unknown as RawEnvironment);
171171

172-
expect(() => readConfig("wrangler.toml", {}))
173-
.toThrowErrorMatchingInlineSnapshot(`
174-
[Error: Extending with configuration found in .wrangler/config/extra.json.
175-
- Expected "compatibility_date" to be of type string but got 2021.]
172+
let error = new Error("Missing expected error");
173+
try {
174+
readConfig("wrangler.toml", {});
175+
} catch (e) {
176+
error = e as Error;
177+
}
178+
179+
expect(error.toString().replaceAll("\\", "/")).toMatchInlineSnapshot(`
180+
"Error: Extending with configuration found in .wrangler/config/extra.json.
181+
- Expected \\"compatibility_date\\" to be of type string but got 2021."
176182
`);
183+
177184
expect(std).toMatchInlineSnapshot(`
178185
Object {
179186
"debug": "",

0 commit comments

Comments
 (0)