Skip to content

Commit

Permalink
test(routes): stop checking for res.text (#1952)
Browse files Browse the repository at this point in the history
  • Loading branch information
hiroppy authored and evilebottnawi committed Jun 3, 2019
1 parent e6d48a3 commit 9a1ad89
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 188 deletions.
14 changes: 0 additions & 14 deletions test/Routes.test.js
Expand Up @@ -19,7 +19,6 @@ describe('Routes', () => {
req.get('/__webpack_dev_server__/live.bundle.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -28,7 +27,6 @@ describe('Routes', () => {
req.head('/__webpack_dev_server__/live.bundle.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -37,7 +35,6 @@ describe('Routes', () => {
req.get('/__webpack_dev_server__/sockjs.bundle.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -46,7 +43,6 @@ describe('Routes', () => {
req.head('/__webpack_dev_server__/sockjs.bundle.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -55,7 +51,6 @@ describe('Routes', () => {
req.get('/webpack-dev-server.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -64,7 +59,6 @@ describe('Routes', () => {
req.head('/webpack-dev-server.js').then(({ res }) => {
expect(res.headers['content-type']).toEqual('application/javascript');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -73,7 +67,6 @@ describe('Routes', () => {
req.get('/webpack-dev-server/').then(({ res }) => {
expect(res.headers['content-type']).toEqual('text/html');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -82,7 +75,6 @@ describe('Routes', () => {
req.head('/webpack-dev-server/').then(({ res }) => {
expect(res.headers['content-type']).toEqual('text/html');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -91,7 +83,6 @@ describe('Routes', () => {
req.get('/webpack-dev-server').then(({ res }) => {
expect(res.headers['content-type']).toEqual('text/html');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand All @@ -100,39 +91,34 @@ describe('Routes', () => {
req.head('/webpack-dev-server').then(({ res }) => {
expect(res.headers['content-type']).toEqual('text/html');
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});

it('GET request to magic html', (done) => {
req.get('/main').then(({ res }) => {
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});

it('HEAD request to magic html', (done) => {
req.head('/main').then(({ res }) => {
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});

it('GET request to main chunk', (done) => {
req.get('/main.js').then(({ res }) => {
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});

it('HEAD request to main chunk', (done) => {
req.head('/main.js').then(({ res }) => {
expect(res.statusCode).toEqual(200);
expect(res.text).toMatchSnapshot();
done();
});
});
Expand Down
174 changes: 0 additions & 174 deletions test/__snapshots__/Routes.test.js.snap

This file was deleted.

0 comments on commit 9a1ad89

Please sign in to comment.