@Test public void testCloseEditMode() { doReturn(dataType).when(listItem).getDataType(); listItem.closeEditMode(); verify(view).showEditButton(); verify(view).hideDataTypeNameInput(); verify(view).disableFocusMode(); verify(view).hideListContainer(); verify(listItem).refreshListYesLabel(); verify(dataTypeSelectComponent).disableEditMode(); verify(dataTypeConstraintComponent).disableEditMode(); verify(editModeToggleEvent).fire(eventArgumentCaptor.capture()); assertFalse(eventArgumentCaptor.getValue().isEditModeEnabled()); }
void closeEditMode() { view.hideDataTypeNameInput(); view.hideListContainer(); view.showEditButton(); view.disableFocusMode(); refreshListYesLabel(); dataTypeSelectComponent.disableEditMode(); dataTypeConstraintComponent.disableEditMode(); editModeToggleEvent.fire(new DataTypeEditModeToggleEvent(false, this)); }
DataTypeListItem { void closeEditMode() { view.hideDataTypeNameInput(); view.hideListContainer(); view.showEditButton(); view.disableFocusMode(); refreshListYesLabel(); dataTypeSelectComponent.disableEditMode(); dataTypeConstraintComponent.disableEditMode(); editModeToggleEvent.fire(new DataTypeEditModeToggleEvent(false, this)); } }
DataTypeListItem { void closeEditMode() { view.hideDataTypeNameInput(); view.hideListContainer(); view.showEditButton(); view.disableFocusMode(); refreshListYesLabel(); dataTypeSelectComponent.disableEditMode(); dataTypeConstraintComponent.disableEditMode(); editModeToggleEvent.fire(new DataTypeEditModeToggleEvent(false, this)); } @Inject  DataTypeListItem(final View view,
                            final DataTypeSelect dataTypeSelectComponent,
                            final DataTypeConstraint dataTypeConstraintComponent,
                            final SmallSwitchComponent dataTypeListComponent,
                            final DataTypeManager dataTypeManager,
                            final DataTypeConfirmation confirmation,
                            final DataTypeNameFormatValidator nameFormatValidator,
                            final Event<DataTypeEditModeToggleEvent> editModeToggleEvent,
                            final Event<DataTypeChangedEvent> dataTypeChangedEvent); }
DataTypeListItem { void closeEditMode() { view.hideDataTypeNameInput(); view.hideListContainer(); view.showEditButton(); view.disableFocusMode(); refreshListYesLabel(); dataTypeSelectComponent.disableEditMode(); dataTypeConstraintComponent.disableEditMode(); editModeToggleEvent.fire(new DataTypeEditModeToggleEvent(false, this)); } @Inject  DataTypeListItem(final View view,
                            final DataTypeSelect dataTypeSelectComponent,
                            final DataTypeConstraint dataTypeConstraintComponent,
                            final SmallSwitchComponent dataTypeListComponent,
                            final DataTypeManager dataTypeManager,
                            final DataTypeConfirmation confirmation,
                            final DataTypeNameFormatValidator nameFormatValidator,
                            final Event<DataTypeEditModeToggleEvent> editModeToggleEvent,
                            final Event<DataTypeChangedEvent> dataTypeChangedEvent); void init(final DataTypeList dataTypeList); DataType getDataType(); boolean isReadOnly(); int getLevel(); boolean isCollapsed(); void expand(); void collapse(); void enableEditMode(); void disableEditMode(); void saveAndCloseEditMode(); void remove(); Command removeItem(); Command destroy(); void destroyWithDependentTypes(); void destroyWithoutDependentTypes(); String getType(); void insertFieldAbove(); String insertFieldAbove(final DataType dataType); void insertFieldBelow(); String insertFieldBelow(final DataType dataType); void insertNestedField(); void insertNestedField(final DataType newDataType); HTMLElement getDragAndDropElement(); void highlightLevel(final DataType dataType); }
DataTypeListItem { void closeEditMode() { view.hideDataTypeNameInput(); view.hideListContainer(); view.showEditButton(); view.disableFocusMode(); refreshListYesLabel(); dataTypeSelectComponent.disableEditMode(); dataTypeConstraintComponent.disableEditMode(); editModeToggleEvent.fire(new DataTypeEditModeToggleEvent(false, this)); } @Inject  DataTypeListItem(final View view,
                            final DataTypeSelect dataTypeSelectComponent,
                            final DataTypeConstraint dataTypeConstraintComponent,
                            final SmallSwitchComponent dataTypeListComponent,
                            final DataTypeManager dataTypeManager,
                            final DataTypeConfirmation confirmation,
                            final DataTypeNameFormatValidator nameFormatValidator,
                            final Event<DataTypeEditModeToggleEvent> editModeToggleEvent,
                            final Event<DataTypeChangedEvent> dataTypeChangedEvent); void init(final DataTypeList dataTypeList); DataType getDataType(); boolean isReadOnly(); int getLevel(); boolean isCollapsed(); void expand(); void collapse(); void enableEditMode(); void disableEditMode(); void saveAndCloseEditMode(); void remove(); Command removeItem(); Command destroy(); void destroyWithDependentTypes(); void destroyWithoutDependentTypes(); String getType(); void insertFieldAbove(); String insertFieldAbove(final DataType dataType); void insertFieldBelow(); String insertFieldBelow(final DataType dataType); void insertNestedField(); void insertNestedField(final DataType newDataType); HTMLElement getDragAndDropElement(); void highlightLevel(final DataType dataType);  }