Improved mocks, improved logging.