@Test
public void testInstanceBinding_2() throws Exception {

	final String result = "{\"name\":\"server\",\"path\":\"/server\",\"status\":\"STARTING\",\"channels\":[\"channel4\",\"hop\"]}";
	ObjectMapper mapper = JSonBindingUtils.createObjectMapper();
	Instance inst = new Instance( "server" ).channel( "channel4" ).channel( "hop" ).status( InstanceStatus.STARTING );
	StringWriter writer = new StringWriter();
	mapper.writeValue( writer, inst );
	String s = writer.toString();
	Assert.assertEquals( result, s );
	Instance readInst = mapper.readValue( result, Instance.class );
	Assert.assertEquals( inst, readInst );
	Assert.assertEquals( inst.getName(), readInst.getName());
	Assert.assertEquals( inst.getStatus(), readInst.getStatus());
	Assert.assertEquals( inst.channels, readInst.channels );
	Assert.assertEquals( "/server", readInst.data.get( AT_INSTANCE_PATH ));
}