public void testGenericBlock() {
GenericBlock o = new GenericBlock();
o.setId("a");
o.setVersion("1");
Check inputConstraints = new Check();
inputConstraints.setConstraints(Arrays.asList(new Constraint[] { new DummyConstraint(1), new DummyConstraint(2) }));
o.setInputConstraints(inputConstraints);
Check outputConstraints = new Check();
outputConstraints.setConstraints(Arrays.asList(new Constraint[] { new DummyConstraint(3), new DummyConstraint(4) }));
o.setOutputConstraints(outputConstraints);
// Test correct class and differing object instances
final Object ocopy = o.clone();
Assert.assertTrue(ocopy instanceof GenericBlock);
Assert.assertFalse(o == ocopy);
final GenericBlock copy = (GenericBlock) ocopy;
// Test attributes
Assert.assertEquals(Arrays.asList(new Constraint[] { new DummyConstraint(1), new DummyConstraint(2) }), copy.getInputConstraints().getConstraints());
Assert.assertFalse(o.getInputConstraints() == copy.getInputConstraints());
TestUtils.assertListItemsNotSame(o.getInputConstraints().getConstraints(), copy.getInputConstraints().getConstraints());
Assert.assertEquals(Arrays.asList(new Constraint[] { new DummyConstraint(3), new DummyConstraint(4) }), copy.getOutputConstraints().getConstraints());
Assert.assertFalse(o.getOutputConstraints() == copy.getOutputConstraints());
TestUtils.assertListItemsNotSame(o.getOutputConstraints().getConstraints(), copy.getOutputConstraints().getConstraints());
}