added tests for toString and class