Skip to content

Commit

Permalink
test(cli): add windows support
Browse files Browse the repository at this point in the history
  • Loading branch information
hiroppy committed Apr 28, 2020
1 parent 80fd37c commit 6d5b6b1
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion test/cli/cli.test.js
Expand Up @@ -108,8 +108,15 @@ describe('CLI', () => {
it('--color', (done) => {
testBin('--color')
.then((output) => {
console.log('out', output);

// https://github.com/webpack/webpack-dev-server/blob/master/lib/utils/colors.js
expect(output.stdout).toContain('\u001b[34m⬡ wds: \u001b[39m');
const text =
process.platform === 'win32'
? '\u001b[94m⬡ wds: \u001b[39m'
: '\u001b[34m⬡ wds: \u001b[39m';

expect(output.stdout).toContain(text);
done();
})
.catch(done);
Expand Down

0 comments on commit 6d5b6b1

Please sign in to comment.