@Test
public void testFromJsonObject() {

	JsonArrayBuilder array = Json.createArrayBuilder();
	for (int d : a1.getData()) {
		array.add(d);
	}
	JsonObject jsonObject = Json
			.createObjectBuilder()
			.add(Int32MultiArray.FIELD_DATA, array.build())
			.add(Int32MultiArray.FIELD_LAYOUT,
					a1.getLayout().toJsonObject()).build();
	Int32MultiArray p = Int32MultiArray.fromJsonObject(jsonObject);
	assertEquals(a1.toString(), p.toString());
	assertEquals(a1.toJsonObject(), p.toJsonObject());
	assertEquals(a1.getMessageType(), p.getMessageType());
	assertTrue(Arrays.equals(a1.getData(), p.getData()));
	assertEquals(a1.getLayout(), p.getLayout());
	assertNotSame(a1, p);
	assertNotSame(a1.toString(), p.toString());
	assertNotSame(a1.toJsonObject(), p.toJsonObject());
	assertEquals(a1.size(), p.size());
}