Skip to content
Myr

nested-pipe-stream.js

This file

Path

test/fixtures/nested-pipe-stream.js

12 lines · 374 bytes · JavaScript

Last changed by

Refactor test helpers for the `verbose` option (#1128)ehmickybefore adoption18d320f

History of this file

Take it

The walk stopped after 200 commits: lines older than 9f65b86 point at it.

100% test coverage (#1018)ehmickybefore adoption9f65b86

lines 1–2why, one step back
1#!/usr/bin/env node
2import process from 'node:process';

Refactor test helpers for the `verbose` option (#1128)ehmickybefore adoption18d320f

line 3why, one step back
3import {execa, getOneMessage} from '../../index.js';

100% test coverage (#1018)ehmickybefore adoption9f65b86

line 4why, one step back
4

Refactor test helpers for the `verbose` option (#1128)ehmickybefore adoption18d320f

lines 5–6why, one step back
5const {file, commandArguments, options: {unpipe, ...options}} = await getOneMessage();
6const subprocess = execa(file, commandArguments, options);

100% test coverage (#1018)ehmickybefore adoption9f65b86

line 7why, one step back
7subprocess.stdout.pipe(process.stdout);

Refactor test helpers for the `verbose` option (#1128)ehmickybefore adoption18d320f

line 8why, one step back
8if (unpipe) {

100% test coverage (#1018)ehmickybefore adoption9f65b86

lines 9–12why, one step back
9 subprocess.stdout.unpipe(process.stdout);
10}1112await subprocess;