| 1 |
'use strict' |
| 2 |
|
| 3 |
const path = require('path') |
| 4 |
const t = require('tap') |
| 5 |
|
| 6 |
const { testSuccess } = require('./helpers') |
| 7 |
const fixturesTSC = path.resolve(__dirname, 'fixtures/tsc') |
| 8 |
|
| 9 |
t.test('reads source-map', t => testSuccess(t, { |
| 10 |
cwd: fixturesTSC, |
| 11 |
args: [ |
| 12 |
'--produce-source-map=true', |
| 13 |
'--cache=false', |
| 14 |
process.execPath, |
| 15 |
'mapping.js' |
| 16 |
] |
| 17 |
})) |
| 18 |
|
| 19 |
t.test('ignore source-map', t => testSuccess(t, { |
| 20 |
cwd: fixturesTSC, |
| 21 |
args: [ |
| 22 |
'--produce-source-map=true', |
| 23 |
'--no-source-map', |
| 24 |
'--cache=false', |
| 25 |
process.execPath, |
| 26 |
'mapping.js' |
| 27 |
] |
| 28 |
})) |