@SuppressWarnings("unchecked")
@Test
public void setAttributes() throws Exception {

	Date date = new Date();
	Map<String, Attribute> attributes = new HashMap<String, Attribute>();
	attributes.put(PARAM_TEXT_ATTR, new StringAttribute("new name"));
	attributes.put(PARAM_INT_ATTR, new IntegerAttribute(5));
	attributes.put(PARAM_FLOAT_ATTR, new FloatAttribute(5.0f));
	attributes.put(PARAM_DOUBLE_ATTR, new DoubleAttribute(5.0));
	attributes.put(PARAM_BOOLEAN_ATTR, new BooleanAttribute(false));
	attributes.put(PARAM_DATE_ATTR, new DateAttribute(date));
	featureModel.setAttributes(feature1, attributes);
	Assert.assertEquals("new name", featureModel.getAttribute(feature1, PARAM_TEXT_ATTR).getValue());
	Assert.assertEquals(5, featureModel.getAttribute(feature1, PARAM_INT_ATTR).getValue());
	Assert.assertEquals(5.0f, featureModel.getAttribute(feature1, PARAM_FLOAT_ATTR).getValue());
	Assert.assertEquals(5.0, featureModel.getAttribute(feature1, PARAM_DOUBLE_ATTR).getValue());
	Assert.assertFalse((Boolean) featureModel.getAttribute(feature1, PARAM_BOOLEAN_ATTR).getValue());
	Assert.assertEquals(date, featureModel.getAttribute(feature1, PARAM_DATE_ATTR).getValue());
}