@Test
public void testSetAllAttributes() {

	// mixed
	Map<String, Attribute<?>> attrs = new HashMap<String, Attribute<?>>();
	attrs.put("orig", new ManyToOneAttribute());
	AssociationValue value = new AssociationValue(new StringAttribute("1"), attrs, false);
	Map<String, Attribute<?>> attrs2 = new HashMap<String, Attribute<?>>();
	attrs2.put("new", new ManyToOneAttribute());
	value.setAllAttributes(attrs2);
	Assert.assertSame(attrs2, value.getAllAttributes());
	
	// primitive
	Map<String, Attribute<?>> attrs3 = new HashMap<String, Attribute<?>>();
	attrs3.put("orig", new StringAttribute("orig"));
	AssociationValue value2 = new AssociationValue(new StringAttribute("1"), attrs3, true);
	Map<String, Attribute<?>> attrs4 = new HashMap<String, Attribute<?>>();
	attrs4.put("new", new StringAttribute("new"));
	value2.setAllAttributes(attrs4);
	Assert.assertSame(attrs4, value2.getAllAttributes());
}