Message implements Serializable { @Override public String toString() { return getClass().getSimpleName(); }  @Override String toString();  }
@Test public void testToString() { MsgCmdRemoveInstance msg1 = new MsgCmdRemoveInstance( "/path" ); Assert.assertEquals( "MsgCmdRemoveInstance", msg1.toString()); MsgCmdResynchronize msg2 = new MsgCmdResynchronize(); Assert.assertEquals( "MsgCmdResynchronize", msg2.toString()); }