@Test
public void clearValue() {

    AbstractFormItem<String> noExpression = formItem(false);
    boolean modified = noExpression.isModified();
    boolean undefined = noExpression.isUndefined();
    noExpression.clearValue();
    assertNull(noExpression.getValue());
    assertNull(noExpression.getExpressionValue());
    assertEquals(modified, noExpression.isModified());
    assertEquals(undefined, noExpression.isUndefined());
    verify(readOnlyAppearance).clearValue();
    verify(readOnlyAppearance).unapply(INVALID);
    verify(editingAppearance).clearValue();
    verify(editingAppearance).unapply(INVALID);
    reset(readOnlyAppearance, editingAppearance);
    AbstractFormItem<String> expression = formItem(true);
    modified = expression.isModified();
    undefined = expression.isUndefined();
    expression.clearValue();
    assertNull(expression.getValue());
    assertNull(expression.getExpressionValue());
    assertEquals(modified, expression.isModified());
    assertEquals(undefined, expression.isUndefined());
    verify(readOnlyAppearance).clearValue();
    verify(readOnlyAppearance).unapply(INVALID);
    verify(readOnlyAppearance).unapply(EXPRESSION);
    verify(editingAppearance).clearValue();
    verify(editingAppearance).unapply(INVALID);
    verify(editingAppearance).unapply(EXPRESSION);
}