mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test: use sourcemaps in unit tests (#6485)
Introduce the source-map-support package and require it for mocha running unit tests. Turn on the sourceMap option for tsconfig.base.json so that the sourceMappingURL= line is emitted in the generated files. Co-authored-by: Mathias Bynens <mathias@qiwi.be>
This commit is contained in:
parent
fb859115c0
commit
46e74ff3f5
@ -18,7 +18,11 @@ const base = require('./base');
|
||||
|
||||
module.exports = {
|
||||
...base,
|
||||
require: ['./test/mocha-ts-require', './test/mocha-utils.ts'],
|
||||
require: [
|
||||
'./test/mocha-ts-require',
|
||||
'./test/mocha-utils.ts',
|
||||
'source-map-support/register',
|
||||
],
|
||||
spec: 'test/*.spec.ts',
|
||||
extension: ['js', 'ts'],
|
||||
retries: process.env.CI ? 2 : 0,
|
||||
|
@ -96,6 +96,7 @@
|
||||
"pngjs": "^5.0.0",
|
||||
"prettier": "^2.1.2",
|
||||
"sinon": "^9.0.2",
|
||||
"source-map-support": "^0.5.19",
|
||||
"standard-version": "^9.0.0",
|
||||
"text-diff": "^1.0.1",
|
||||
"ts-node": "^9.0.0",
|
||||
|
@ -8,6 +8,7 @@
|
||||
"module": "ESNext",
|
||||
"declaration": true,
|
||||
"declarationMap": true,
|
||||
"resolveJsonModule": true
|
||||
"resolveJsonModule": true,
|
||||
"sourceMap": true,
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user