added some more unit tests
Added lots of tests to make sure we correctly prefix streams split in different places. Fixed code to support this.