Skip to content

Commit

Permalink
Show correct error message on initial load
Browse files Browse the repository at this point in the history
Reviewed By: cpojer

Differential Revision: D16073931

fbshipit-source-id: a70ae28635b72f674cb1da26f89744b4214f18d9
  • Loading branch information
gaearon authored and facebook-github-bot committed Jul 1, 2019
1 parent 49bce29 commit dc2f29f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/metro/src/Server/__tests__/Server-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -532,6 +532,10 @@ describe('processRequest', () => {
expect(() => JSON.parse(response.body)).not.toThrow();
const body = JSON.parse(response.body);
expect(body).toMatchObject({
// CAUTION -- these *exact* field names are important because
// they are being parsed by DebugServerException.java on Android.
// DO NOT change them without also ensuring that a transform error
// still shows a meaningful message on the initial bundle load.
type: 'TransformError',
message: 'test syntax error',
});
Expand Down

0 comments on commit dc2f29f

Please sign in to comment.