source: trip-planner-front/node_modules/minimist/test/stop_early.js@ eed0bf8

Last change on this file since eed0bf8 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 328 bytes
RevLine 
[6a3a178]1var parse = require('../');
2var test = require('tape');
3
4test('stops parsing on the first non-option when stopEarly is set', function (t) {
5 var argv = parse(['--aaa', 'bbb', 'ccc', '--ddd'], {
6 stopEarly: true
7 });
8
9 t.deepEqual(argv, {
10 aaa: 'bbb',
11 _: ['ccc', '--ddd']
12 });
13
14 t.end();
15});
Note: See TracBrowser for help on using the repository browser.