Skip to content

Commit

Permalink
test: increase coverage for internal/module.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Tamás Hódi committed Jun 14, 2017
1 parent 448c4c6 commit 8404e9f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions test/parallel/test-internal-modules-strip-shebang.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Flags: --expose-internals
'use strict';
require('../common');

const assert = require('assert');
const stripShebang = require('internal/module').stripShebang;

[
['', ''],
['aa', 'aa'],
['#!', ''],
['#!bin/bash', ''],
['#!bin/bash\naa', '\naa'],
].forEach((i) => assert.strictEqual(stripShebang(i[0]), i[1]));

0 comments on commit 8404e9f

Please sign in to comment.