Skip to content
This repository was archived by the owner on Jun 24, 2024. It is now read-only.

Commit 5684cea

Browse files
committed
fix: test snapshots
1 parent 9cfc8b4 commit 5684cea

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

test/integration/__snapshots__/main.test.js.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Jest Snapshot v1, https://goo.gl/fbAQLP
22

3-
exports[`publishAssets(tag, files, options) - 500 error 1`] = `[Error: Asset build server responded with an error. Original message: Server error. Status code: 500. URL: http://127.0.0.1:57336/publish-assets?rebundle=true]`;
3+
exports[`publishAssets(tag, files, options) - 500 error 1`] = `"Error: Asset build server responded with an error. Original message: Server error. Status code: 500. URL: http://127.0.0.1publish-assets?rebundle=true"`;
44

55
exports[`publishAssets(tag, files, options) - css 1`] = `
66
Object {

test/integration/main.test.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -416,9 +416,12 @@ test('publishAssets(tag, files, options) - 500 error', async () => {
416416
]);
417417
const client = new Client({ buildServerUri: `http://127.0.0.1:${port}` });
418418

419-
const result = client.publishAssets('podlet1', ['first.js', 'second.js']);
420-
421-
await expect(result).rejects.toMatchSnapshot();
419+
420+
try {
421+
await client.publishAssets('podlet1', ['first.js', 'second.js']);
422+
} catch(err) {
423+
expect(String(err).replace(/:[0-9]+\//, '')).toMatchSnapshot();
424+
}
422425
await closeServer(server);
423426
});
424427

0 commit comments

Comments
 (0)