Make it work!!!! Added a ByteArray stream to fake writing internally before actually writing!!