Skip to content

Commit

Permalink
Merge pull request #119 from davidchambers/avaq/node-12
Browse files Browse the repository at this point in the history
Support Node 12
  • Loading branch information
davidchambers authored Jun 6, 2019
2 parents 5d7fe83 + 4b4b128 commit c93f5cd
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
sudo: false
language: node_js
node_js:
- "6"
- "8"
- "9"
- "10"
- "12"
before_install:
- git fetch origin refs/heads/master:refs/heads/master
- if [[ "$TRAVIS_PULL_REQUEST_BRANCH" ]] ; then git checkout -b "$TRAVIS_PULL_REQUEST_BRANCH" ; fi
6 changes: 5 additions & 1 deletion bin/doctest
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ require ('child_process')
process.execPath,
[].concat (esmSupported ? ['--experimental-modules'] : [])
.concat (flags ? args[idx + 1].split (/\s+/) : [])
.concat (['--', path.resolve (__dirname, '..', 'lib', 'command')])
.concat (['--',
path.resolve (__dirname,
'..',
'lib',
'command' + (esmSupported ? '.mjs' : '.js'))])
.concat (flags ? (args.slice (0, idx)).concat (args.slice (idx + 2))
: args),
{cwd: process.cwd (), env: process.env, stdio: [0, 1, 2]}
Expand Down
6 changes: 3 additions & 3 deletions lib/command.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import common from './common';
import program from './program';
import doctest from '..';
import common from './common.js';
import doctest from './doctest.mjs';
import program from './program.js';

common.runDoctests (doctest, program);
2 changes: 1 addition & 1 deletion lib/doctest.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import fs from 'fs';
import pathlib from 'path';
import util from 'util';

import common from './common';
import common from './common.js';
import doctest from './doctest.js';


Expand Down

0 comments on commit c93f5cd

Please sign in to comment.