MCPcopy Create free account
hub / github.com/unconed/TermKit / testPipe

Function testPipe

Node/test.js:545–560  ·  view source on GitHub ↗

* Test command pipelines.

(assert)

Source from the content-addressed store, hash-verified

543 * Test command pipelines.
544 */
545function testPipe(assert) {
546
547 mockShell([
548 { query: 8, method: 'shell.run', args: { tokens: [ [ 'ls' ], [ 'grep', '.js' ] ], ref: 7 } },
549 ], function (messages, success) {
550 /*
551 for (i in messages) {
552 console.log(messages[i]);
553 messages[i].args && messages[i].args.objects && console.log('Objects', messages[i].args.objects);
554 }
555 */
556 var last = messages[messages.length - 1];
557 assert(last.success && last.answer == 8, "Run pipelined command");
558 });
559
560}
561
562/**
563 * Test binary handling.

Callers

nothing calls this directly

Calls 2

mockShellFunction · 0.85
assertFunction · 0.85

Tested by

no test coverage detected