DataObjectFieldPicker implements DataObjectFieldPickerView.Presenter,
                                              IsWidget { @Override public void onMoveFieldPickerItemUp(DataObjectFieldPickerItem fieldPickerItem) { int currentIndex = fieldPickerItemList.indexOf(fieldPickerItem); view.moveFieldItemUp(currentIndex); if (currentIndex > 0) { DataObjectFieldPickerItem swapWithItem = fieldPickerItemList.get(currentIndex - 1); swapWithItem.setFieldPickerItemIndex(currentIndex + 1); fieldPickerItem.setFieldPickerItemIndex(currentIndex); Collections.swap(fieldPickerItemList, currentIndex, currentIndex - 1); } objectPropertyPathChanged(false); } @Inject  DataObjectFieldPicker(final DataObjectFieldPickerView view,
                                 final ManagedInstance<DataObjectFieldPickerItem> fieldPickerItemProducer); void init(DataModel dataModel,
                     DataObject rootDataObject,
                     List<ObjectPropertyPath> objectPropertyPaths,
                     PlannerDataObjectEditorView.Presenter presenter); void destroy(); @Override void onFieldPickerItemRemoved(DataObjectFieldPickerItem fieldPickerItem); @Override void onComparatorSpecified(boolean specified); @Override void onMoveFieldPickerItemUp(DataObjectFieldPickerItem fieldPickerItem); @Override void onMoveFieldPickerItemDown(DataObjectFieldPickerItem fieldPickerItem); @Override DataObjectFieldPickerItem addFieldPickerItem(); @Override Widget asWidget(); void objectPropertyPathChanged(boolean itemsRemoved); boolean isEmpty();  }
@Test public void onMoveFieldPickerItemUp() { initFieldPicker(); fieldPicker.onMoveFieldPickerItemUp(any(DataObjectFieldPickerItem.class)); verify(view, times(1)).moveFieldItemUp(anyInt()); }