pushed test code into a class.