Fix compressed stream read_array/write_array.
Add compressed stream tests.