Updated the tests and added new ones.