Skip to content

Commit

Permalink
Removed explicit use of ts-node (#1125)
Browse files Browse the repository at this point in the history
* Remove explicit use of ts-node, and dependency. Speed tests.

* Fix typo
  • Loading branch information
shadowspawn authored Dec 20, 2019
1 parent 9de0968 commit 808d4bc
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 44 deletions.
53 changes: 12 additions & 41 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"eslint-plugin-jest": "^22.21.0",
"jest": "^24.8.0",
"standard": "^14.3.1",
"ts-node": "^8.5.2",
"typescript": "^3.7.2"
},
"typings": "typings/index.d.ts",
Expand Down
6 changes: 4 additions & 2 deletions tests/command.executableSubcommand.lookup.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,11 @@ testOrSkipOnWindows('when subcommand file is double symlink then lookup succeeds
});

test('when subcommand suffix is .ts then lookup succeeds', (done) => {
jest.setTimeout(20000); // Extend timeout for GitHub Actions
// We support looking for ts files for ts-node in particular, but don't need to test ts-node itself.
// The program and the subcommand `pm-install.ts` are both plain JavaScript code.
const binLinkTs = path.join(__dirname, 'fixtures-ts', 'pm.ts');
childProcess.execFile('node', ['-r', 'ts-node/register', binLinkTs, 'install'], function(_error, stdout, stderr) {
// childProcess.execFile('node', ['-r', 'ts-node/register', binLinkTs, 'install'], function(_error, stdout, stderr) {
childProcess.execFile('node', [binLinkTs, 'install'], function(_error, stdout, stderr) {
expect(stdout).toBe('install\n');
done();
});
Expand Down

0 comments on commit 808d4bc

Please # to comment.