Some tests and minor changes.