### Question:
User implements Serializable { public String toString() { return "user[userId=" + userId + ", firstName=" + firstName + ", lastName=" + lastName + "]"; } User(String userId, String firstName, String lastName); String getUserId(); void setUserId(String userId); String getFirstName(); void setFirstName(String firstName); String getLastName(); void setLastName(String lastName); String getName(); String toString();  }### Answer:
@Test public void testToString() { user.setUserId("admin"); user.setFirstName("Jane"); user.setLastName("Doe"); assertEquals( "user[userId=admin, firstName=Jane, lastName=Doe]", user.toString()); }