Skip to content

Commit

Permalink
tests(no-options): refactor tests
Browse files Browse the repository at this point in the history
  • Loading branch information
evenstensberg committed Jun 2, 2018
1 parent 9475b17 commit 7be10d8
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 24 deletions.
9 changes: 0 additions & 9 deletions test/binCases/no-options/development/stdin.js

This file was deleted.

1 change: 0 additions & 1 deletion test/binCases/no-options/development/tests.opts

This file was deleted.

1 change: 0 additions & 1 deletion test/binCases/no-options/development/webpack.config.js

This file was deleted.

8 changes: 4 additions & 4 deletions test/binCases/no-options/none/stdin.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
"use strict";

module.exports = function testAssertions(code, stdout, stderr) {
expect(code).toBe(0);
expect(code).toBe(2);
expect(stdout).toEqual(expect.anything());
expect(stdout[3]).toContain("Insufficient number of arguments provided");
expect(stdout[4]).toContain("Alternatively, run `webpack(-cli) --help` for usage info");
expect(stderr).toHaveLength(0);
expect(stderr[1]).toContain("Insufficient number of arguments or no entry found.");
expect(stderr[2]).toContain("Alternatively, run 'webpack(-cli) --help' for usage info.");
expect(stderr).toHaveLength(5);
};
8 changes: 4 additions & 4 deletions test/binCases/no-options/production/stdin.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
"use strict";

module.exports = function testAssertions(code, stdout, stderr) {
expect(code).toBe(0);
expect(code).toBe(2);
expect(stdout).toEqual(expect.anything());
expect(stdout[3]).toContain("Insufficient number of arguments provided");
expect(stdout[4]).toContain("Alternatively, run `webpack(-cli) --help` for usage info");
expect(stderr).toHaveLength(0);
expect(stderr[1]).toContain("Insufficient number of arguments or no entry found.");
expect(stderr[2]).toContain("Alternatively, run 'webpack(-cli) --help' for usage info.");
expect(stderr).toHaveLength(5);
};
5 changes: 0 additions & 5 deletions test/binCases/no-options/stdin.js

This file was deleted.

0 comments on commit 7be10d8

Please sign in to comment.