(tree: IProcessTree, input: string, expected: IProcess[])
| 25 | }; |
| 26 | |
| 27 | const assertParses = async (tree: IProcessTree, input: string, expected: IProcess[]) => { |
| 28 | const stubbed = stub(tree, 'createProcess' as any).returns(fakeChildProcess(input)); |
| 29 | try { |
| 30 | const result = await tree.lookup<IProcess[]>((entry, acc) => [...acc, entry], []); |
| 31 | expect(result).to.deep.equal(expected); |
| 32 | } finally { |
| 33 | stubbed.restore(); |
| 34 | } |
| 35 | }; |
| 36 | |
| 37 | // These tests are a handful of samples taken by manually running the process |
| 38 | // tree on given platforms. |
no test coverage detected