Skip to content
Myr

Add tests for some getters (#1369)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by John Gee · committed by GitHub · parent 39eadd7 · Browse files · 3 files+29 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+29 added−0 removed

  • tests:+29 added−0 removed

3 files+29 added−0 removed

modified:tests/command.alias.test.js+14 added
added:tests/command.description.test.js+8 added
modified:tests/options.version.test.js+7 added
163 unmodified lines
164 expect(() => {165 program.parse(['node', 'test', '--version']);166 }).toThrow(myVersion);167 });168169 test('when specify version then can get version', () => {170 const myVersion = '1.2.3';171 const program = new commander.Command();172 program.version(myVersion);173 expect(program.version()).toEqual(myVersion);174 });175});