Improved unit tests.