mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
This reverts commit c5fe1dbdbb.
This commit is contained in:
@@ -22,7 +22,7 @@ const GOLDEN_DIR = path.join(__dirname, 'golden');
|
||||
const OUTPUT_DIR = path.join(__dirname, 'output');
|
||||
const {TestRunner, Reporter, Matchers} = require('../utils/testrunner/');
|
||||
|
||||
const {helper, assert, debugError} = require('../lib/helper');
|
||||
const {helper, assert} = require('../lib/helper');
|
||||
if (process.env.COVERAGE)
|
||||
helper.recordPublicAPICoverage();
|
||||
|
||||
@@ -116,16 +116,9 @@ describe('Page', function() {
|
||||
const rl = require('readline').createInterface({input: state.browser.process().stderr});
|
||||
test.output = '';
|
||||
rl.on('line', onLine);
|
||||
const enableDebugError = !debugError.enabled;
|
||||
if (enableDebugError) {
|
||||
require('debug').enable(debugError.namespace);
|
||||
debugError.log = onLine;
|
||||
}
|
||||
state.tearDown = () => {
|
||||
rl.removeListener('line', onLine);
|
||||
rl.close();
|
||||
if (enableDebugError)
|
||||
debugError.log = () => undefined;
|
||||
};
|
||||
function onLine(line) {
|
||||
test.output += line + '\n';
|
||||
|
||||
Reference in New Issue
Block a user