blob: bffd30e6ebc1e2e6f2d71c70872d8bbb2f10823e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
'use strict';
var assert = require('assert');
var childProcess = require('child_process');
var path = require('path');
describe('Mocha', function () {
this.timeout(2000);
it('should not output colors to pipe', function (cb) {
var command = [path.join('bin', 'mocha'), '--grep', 'missing-test'];
childProcess.execFile(process.execPath, command, function (err, stdout, stderr) {
if (err) return cb(err);
assert(stdout.indexOf('[90m') === -1);
cb(null);
});
});
});
|