### Question:
CollectionDescriptor extends TynamoPropertyDescriptorImpl { public Object clone() { return new CollectionDescriptor(getBeanType(), this); } CollectionDescriptor(Class beanType, TynamoPropertyDescriptor descriptor);  CollectionDescriptor(Class beanType, CollectionDescriptor collectionDescriptor);  CollectionDescriptor(Class beanType, String name, Class type); boolean isCollection(); Class getElementType(); void setElementType(Class elementType); String getInverseProperty(); void setInverseProperty(String inverseProperty); boolean isOneToMany(); void setOneToMany(boolean oneToMany); boolean isChildRelationship(); void setChildRelationship(boolean childRelationship); String getAddExpression(); void setAddExpression(String addExpression); String getRemoveExpression(); void setRemoveExpression(String removeExpression); String getSwapExpression(); void setSwapExpression(String swapExpression); boolean isAllowRemove(); void setAllowRemove(boolean allowRemove); Object clone();  }### Answer:
@Test public void testClone() { CollectionDescriptor bazzesDescriptor = new CollectionDescriptor(Foo.class, "bazzes", Set.class); bazzesDescriptor.setElementType(Baz.class); bazzesDescriptor.setOneToMany(true); bazzesDescriptor.setChildRelationship(true); bazzesDescriptor.setInverseProperty("inverse"); CollectionDescriptor clonedDescriptor = (CollectionDescriptor) bazzesDescriptor.clone(); assertTrue(clonedDescriptor.isChildRelationship()); assertEquals("inverse", clonedDescriptor.getInverseProperty()); assertTrue(clonedDescriptor.isOneToMany()); }