stream and unit tests