change approach again

This commit is contained in:
2018-05-09 14:31:22 +02:00
parent 54a933c83a
commit 0686e02b75
2252 changed files with 864743 additions and 270 deletions

33
node_modules/command-line-args/test/multiple.js generated vendored Normal file
View File

@ -0,0 +1,33 @@
'use strict'
const TestRunner = require('test-runner')
const commandLineArgs = require('../')
const a = require('assert')
const runner = new TestRunner()
runner.test('multiple: string unset', function () {
const argv = []
const optionDefinitions = [
{ name: 'one', multiple: true }
]
const result = commandLineArgs(optionDefinitions, { argv })
a.deepStrictEqual(result, { })
})
runner.test('multiple: string unset with defaultValue', function () {
const argv = []
const optionDefinitions = [
{ name: 'one', multiple: true, defaultValue: 1 }
]
const result = commandLineArgs(optionDefinitions, { argv })
a.deepStrictEqual(result, { one: [ 1 ]})
})
runner.test('multiple: boolean unset', function () {
const argv = []
const optionDefinitions = [
{ name: 'one', type: Boolean, multiple: true }
]
const result = commandLineArgs(optionDefinitions, { argv })
a.deepStrictEqual(result, { })
})