Skip to content

Commit b764d25

Browse files
authored
chore(dl-center): relax HTTP status code expectation for invalid config (#315)
This seems to have started resulting in 500 rather than 404 errors (which may be a server-side bug, but nothing that affects our package's functional correctness).
1 parent e3a832c commit b764d25

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

packages/dl-center/src/download-center.spec.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,11 @@ describe('download center client', function () {
129129
const error = await downloadCenter
130130
.uploadConfig('prefix/compass.json', invalidConfig)
131131
.catch((e) => e);
132-
133-
expect(error.message).equal(
134-
'Download center urls broken:\n' +
135-
'- http://example.com/non-existing-url -> 404'
132+
expect(error.message).to.match(
133+
new RegExp(
134+
'Download center urls broken:\n' +
135+
'- http://example.com/non-existing-url -> [45][0-9][0-9]'
136+
)
136137
);
137138
});
138139
});

0 commit comments

Comments
 (0)