Changed str to test.
Stream is now coming from file
added fs