@Override
 public void setParameters(List<IParameter> parameters) {
   firePropertyChange(PROPERTY_PARAMETERS, this.parameters, this.parameters = parameters);
   this.originalValueMap = new HashMap<String, String>(this.parameters.size());
   for (IParameter param : parameters) {
     originalValueMap.put(param.getName(), param.getValue());
   }
 }
  @Test
  public void resetParameterShouldSetTheOriginalValue() {
    IParameter param = mock(IParameter.class);
    when(param.getName()).thenReturn("foo");
    when(param.getValue()).thenReturn("abc");
    when(param.clone()).thenReturn(param);

    model.setParameters(Arrays.asList(new IParameter[] {param}));
    model.resetParameter(param);

    verify(param).setValue("abc");
  }