Refactored the way the tests work for doubles.