Add mode option to `save_hdf5`, rename `dataset`->`key`.

Also make tests more robust:

1) Use random-ish filenames for test output files.
2) Remove temporary test files after tests.

All the client tests and MPI tests run without error separately, but when I run them one after the other, there's still an error somewhere.