Added test: should not write undefined to stream or end stream if no args are passed
Modified existing stream tests to end the stream