Resource r = mockResource();
Logger logger = mockLogger();
replay();
MutableComponentModel model = new MutableComponentModelImpl(CLASS_NAME, logger, r, null, false);
assertTrue(model.getParameterNames().isEmpty());
String parameterName = "value";
model.addParameter(parameterName, true, true, BindingConstants.PROP);
ParameterModel pm = model.getParameterModel(parameterName);
assertEquals(pm.getName(), parameterName);
assertEquals(true, pm.isRequired());
assertEquals(pm.getDefaultBindingPrefix(), BindingConstants.PROP);
assertEquals(model.getDeclaredParameterNames(), Arrays.asList(parameterName));
// Verify that the binding prefix is actually stored:
model.addParameter("fred", true, true, "flint");
// Checks that parameter names are case insensitive
assertEquals(model.getParameterModel("Fred").getDefaultBindingPrefix(), "flint");
verify();
}