@Test
public void testFromJsonObject() {

	JsonArrayBuilder array = Json.createArrayBuilder();
	for (GoalStatus p : g1.getStatusList()) {
		array.add(p.toJsonObject());
	}
	JsonObject jsonObject = Json
			.createObjectBuilder()
			.add(GoalStatusArray.FIELD_HEADER,
					g1.getHeader().toJsonObject())
			.add(GoalStatusArray.FIELD_STATUS_LIST, array.build()).build();
	GoalStatusArray p = GoalStatusArray.fromJsonObject(jsonObject);
	assertEquals(g1.toString(), p.toString());
	assertEquals(g1.toJsonObject(), p.toJsonObject());
	assertEquals(g1.getMessageType(), p.getMessageType());
	assertEquals(g1.size(), p.size());
	assertEquals(g1.getHeader(), p.getHeader());
	assertTrue(Arrays.deepEquals(g1.getStatusList(), p.getStatusList()));
	assertNotSame(g1, p);
	assertNotSame(g1.toString(), p.toString());
	assertNotSame(g1.toJsonObject(), p.toJsonObject());
}