Sort the tables in the compressed stream

The packTestDirectory() function sorts the directory (OTS will reject it
otherwise, need to investigate if OTS ought to sort it itself), so we
need to sort the data stream as well since there is no offsets and the
tables are accessed sequentially.