~cyphermox/cordova-cli/flatten

« back to all changes in this revision

Viewing changes to node_modules/cordova/node_modules/optimist/test/short.js

  • Committer: Mathieu Trudel-Lapierre
  • Date: 2013-12-12 05:26:53 UTC
  • Revision ID: mathieu-tl@ubuntu.com-20131212052653-eatjt8zguqua5qmq
testing the flattenage, yo

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
var optimist = require('../index');
2
 
var test = require('tap').test;
3
 
 
4
 
test('-n123', function (t) {
5
 
    t.plan(1);
6
 
    var parse = optimist.parse([ '-n123' ]);
7
 
    t.equal(parse.n, 123);
8
 
});
9
 
 
10
 
test('-123', function (t) {
11
 
    t.plan(3);
12
 
    var parse = optimist.parse([ '-123', '456' ]);
13
 
    t.equal(parse['1'], true);
14
 
    t.equal(parse['2'], true);
15
 
    t.equal(parse['3'], 456);
16
 
});