### Question:
DualListVm { @Command @NotifyChange({LEFT_PROPERTY, RIGHT_PROPERTY, LEFT_SELECTED_PROPERTY, RIGHT_SELECTED_PROPERTY}) public void remove() { stateAfterEdit.removeAll(getRightSelected()); updateVm(); } DualListVm(); @Init void initVm(@BindingParam("fullList") List<Group> fullList,
                       @BindingParam("rightList") List<Group> rightList); String getAvailFilterTxt(); void setAvailFilterTxt(@Nonnull String leftFilterTxt); String getExistFilterTxt(); void setExistFilterTxt(@Nonnull String rightFilterTxt); ListModelList<Group> getLeft(); ListModelList<Group> getRight(); Set<Group> getLeftSelected(); Set<Group> getRightSelected(); @Command @NotifyChange({LEFT_PROPERTY, RIGHT_PROPERTY, LEFT_SELECTED_PROPERTY, RIGHT_SELECTED_PROPERTY}) void add(); @Command @NotifyChange({LEFT_PROPERTY, RIGHT_PROPERTY, LEFT_SELECTED_PROPERTY, RIGHT_SELECTED_PROPERTY}) void addAll(); @Command @NotifyChange({LEFT_PROPERTY, RIGHT_PROPERTY, LEFT_SELECTED_PROPERTY, RIGHT_SELECTED_PROPERTY}) void remove(); @Command @NotifyChange({LEFT_PROPERTY, RIGHT_PROPERTY, LEFT_SELECTED_PROPERTY, RIGHT_SELECTED_PROPERTY}) void removeAll(); @Command @NotifyChange({"leftSelected", "rightSelected"}) void listSelected(); void setStateAfterEdit(List<Group> stateAfterEdit); void setAvail(ListModelList<Group> left); void setExist(ListModelList<Group> right); List<Group> getStateAfterEdit(); static final String LEFT_PROPERTY; static final String LEFT_SELECTED_PROPERTY; }### Answer:
@Test public void testRemove() { list.initVm(fullList, rightGroups); list.getRight().addToSelection(rightGroups.get(0)); list.remove(); assertTrue(!list.getRight().contains(rightGroups.get(0))); assertTrue(list.getLeft().contains(rightGroups.get(0))); }