test: prevent the stream test from exiting early

There is a race condition in the stream test. Occasionally, when the
shell process exits, a process higher up in the chain is killed before
it has completely relayed the data.

Work around the test failure for now by adding a delay.