@Test
public void should_delete_a_widget_property() throws Exception {

    Property aProperty = aProperty().name("aParam").build();
    Widget aWidget = addToRepository(aWidget().property(aProperty).property(aProperty().name("anotherParam")).build());
    List<Property> properties = widgetRepository.deleteProperty(aWidget.getId(), "aParam");
    Widget widget = getFromRepository(aWidget.getId());
    assertThat(widget.getProperties()).doesNotContain(aProperty);
    assertThat(properties).containsOnlyElementsOf(widget.getProperties());
}