specific.js
This file
Path
test/arguments/specific.js
38 lines · 2.9 KiB · JavaScript
Last changed by
Upgrade xo (#980)ehmickybefore adoptionccfa412
History of this fileTake it
Split files into smaller ones (#976)ehmickybefore adoptiond7c6853
lines 1–2why, one step back1import test from 'ava';2import {execa, execaSync} from '../../index.js';Upgrade xo (#980)ehmickybefore adoptionccfa412
line 3why, one step back3import {setFixtureDirectory} from '../helpers/fixtures-directory.js';Split files into smaller ones (#976)ehmickybefore adoptiond7c6853
lines 4–5why, one step back4import {foobarString} from '../helpers/input.js';5Upgrade xo (#980)ehmickybefore adoptionccfa412
line 6why, one step back6setFixtureDirectory();Split files into smaller ones (#976)ehmickybefore adoptiond7c6853
lines 7–38why, one step back78// eslint-disable-next-line max-params9const testPriorityOrder = async (t, buffer, bufferStdout, bufferStderr, execaMethod) => {10 const {stdout, stderr} = await execaMethod('noop-both.js', {buffer});11 t.is(stdout, bufferStdout ? foobarString : undefined);12 t.is(stderr, bufferStderr ? foobarString : undefined);13};1415test('buffer: {stdout, fd1}', testPriorityOrder, {stdout: true, fd1: false}, true, true, execa);16test('buffer: {stdout, all}', testPriorityOrder, {stdout: true, all: false}, true, false, execa);17test('buffer: {fd1, all}', testPriorityOrder, {fd1: true, all: false}, true, false, execa);18test('buffer: {stderr, fd2}', testPriorityOrder, {stderr: true, fd2: false}, true, true, execa);19test('buffer: {stderr, all}', testPriorityOrder, {stderr: true, all: false}, false, true, execa);20test('buffer: {fd2, all}', testPriorityOrder, {fd2: true, all: false}, false, true, execa);21test('buffer: {fd1, stdout}', testPriorityOrder, {fd1: false, stdout: true}, true, true, execa);22test('buffer: {all, stdout}', testPriorityOrder, {all: false, stdout: true}, true, false, execa);23test('buffer: {all, fd1}', testPriorityOrder, {all: false, fd1: true}, true, false, execa);24test('buffer: {fd2, stderr}', testPriorityOrder, {fd2: false, stderr: true}, true, true, execa);25test('buffer: {all, stderr}', testPriorityOrder, {all: false, stderr: true}, false, true, execa);26test('buffer: {all, fd2}', testPriorityOrder, {all: false, fd2: true}, false, true, execa);27test('buffer: {stdout, fd1}, sync', testPriorityOrder, {stdout: true, fd1: false}, true, true, execaSync);28test('buffer: {stdout, all}, sync', testPriorityOrder, {stdout: true, all: false}, true, false, execaSync);29test('buffer: {fd1, all}, sync', testPriorityOrder, {fd1: true, all: false}, true, false, execaSync);30test('buffer: {stderr, fd2}, sync', testPriorityOrder, {stderr: true, fd2: false}, true, true, execaSync);31test('buffer: {stderr, all}, sync', testPriorityOrder, {stderr: true, all: false}, false, true, execaSync);32test('buffer: {fd2, all}, sync', testPriorityOrder, {fd2: true, all: false}, false, true, execaSync);33test('buffer: {fd1, stdout}, sync', testPriorityOrder, {fd1: false, stdout: true}, true, true, execaSync);34test('buffer: {all, stdout}, sync', testPriorityOrder, {all: false, stdout: true}, true, false, execaSync);35test('buffer: {all, fd1}, sync', testPriorityOrder, {all: false, fd1: true}, true, false, execaSync);36test('buffer: {fd2, stderr}, sync', testPriorityOrder, {fd2: false, stderr: true}, true, true, execaSync);37test('buffer: {all, stderr}, sync', testPriorityOrder, {all: false, stderr: true}, false, true, execaSync);38test('buffer: {all, fd2}, sync', testPriorityOrder, {all: false, fd2: true}, false, true, execaSync);