Skip to content
Myr

make `execa.spawn()` use the same argument normalization as `execa()`

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

authored by Sindre Sorhus · committed by Sindre Sorhus · parent 9baf99e · Browse files · 3 files+12 added−2 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+12 added−2 removed

  • other:+12 added−2 removed

3 files+12 added−2 removed

modified:index.js+8 added-1 removed
modified:package.json+1 added
modified:test.js+3 added-1 removed
1import test from 'ava';2import getStream from 'get-stream';3import m from './';45test('execa()', async t => {6 const {stdout} = await m('echo', ['foo']);
27 unmodified lines
34 const {stdout} = await m.shell('echo foo');35 t.is(stdout, 'foo');36});3737test('execa.spawn()', t => {38test('execa.spawn()', async t => {39 t.is(typeof m.spawn('echo').pid, 'number');40 t.is((await getStream(m.spawn('echo', ['foo']).stdout)).trim(), 'foo');41});4243test('stripEof option', async t => {44 const {stdout} = await m('echo', ['foo'], {stripEof: false});
18 unmodified lines