test_class.file: dataprep-upgrade-common/src/test/java/org/talend/dataprep/upgrade/common/ActionNewColumnToggleCommonTest.java
test_class.identifier: ActionNewColumnToggleCommonTest
test_case.body: @Test
      public void shouldNotUpdateSteps() {
          // given
          final PreparationRepository repository = mock(PreparationRepository.class);
          final PreparationActions actions = mock(PreparationActions.class);
          final PersistentStep step = mock(PersistentStep.class);
          final Action action = mock(Action.class);
          List<Action> actionsList = new ArrayList<>();
          actionsList.add(action);
  
          when(step.id()).thenReturn("step-1");
          when(actions.getActions()).thenReturn(actionsList);
          when(action.getName()).thenReturn("action");
          when(repository.list(eq(PreparationActions.class))).thenReturn(Stream.of(actions));
          // Twice "action-1" to pass root preparation action filter.
          when(actions.id()).thenReturn("actions-1", "actions-1", "actions-1"); // same id
          when(repository.list(eq(PersistentStep.class), any())).thenReturn(Stream.of(step));
  
          // when
          ActionNewColumnToggleCommon.upgradeActions(repository);
  
          // then
          verify(repository, times(1)).add(eq(actions));
          verify(repository, never()).add(eq(step));
          verify(step, never()).setContent(any());
      }
test_case.class_method_signature: ActionNewColumnToggleCommonTest.shouldNotUpdateSteps()
test_case.full_signature: @Test public void shouldNotUpdateSteps()
test_case.identifier: shouldNotUpdateSteps
test_case.invocations: mock mock mock mock add thenReturn when id thenReturn when getActions thenReturn when getName thenReturn when list eq of thenReturn when id thenReturn when list eq any of upgradeActions add verify times eq add verify never eq setContent verify never any
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void shouldNotUpdateSteps()
focal_class.declarator: LOGGER = getLogger(ActionNewColumnToggleCommon.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = getLogger(ActionNewColumnToggleCommon.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.file: dataprep-upgrade-common/src/main/java/org/talend/dataprep/upgrade/common/ActionNewColumnToggleCommon.java
focal_class.identifier: ActionNewColumnToggleCommon
focal_class.class_method_signature: ActionNewColumnToggleCommon.ActionNewColumnToggleCommon()
focal_class.full_signature: private  ActionNewColumnToggleCommon()
focal_class.identifier: ActionNewColumnToggleCommon
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.signature:  ActionNewColumnToggleCommon()
focal_class.class_method_signature: ActionNewColumnToggleCommon.upgradeActions(PreparationRepository preparationRepository)
focal_class.full_signature: public static void upgradeActions(PreparationRepository preparationRepository)
focal_class.identifier: upgradeActions
focal_class.modifiers: public static
focal_class.parameters: (PreparationRepository preparationRepository)
focal_class.return: void
focal_class.signature: void upgradeActions(PreparationRepository preparationRepository)
focal_class.class_method_signature: ActionNewColumnToggleCommon.shouldAddCreateNewColumnParameter(Action action)
focal_class.full_signature: private static boolean shouldAddCreateNewColumnParameter(Action action)
focal_class.identifier: shouldAddCreateNewColumnParameter
focal_class.modifiers: private static
focal_class.parameters: (Action action)
focal_class.return: boolean
focal_class.signature: boolean shouldAddCreateNewColumnParameter(Action action)
focal_class.class_method_signature: ActionNewColumnToggleCommon.updateAction(Action action)
focal_class.full_signature: private static void updateAction(Action action)
focal_class.identifier: updateAction
focal_class.modifiers: private static
focal_class.parameters: (Action action)
focal_class.return: void
focal_class.signature: void updateAction(Action action)
focal_method.body: public static void upgradeActions(PreparationRepository preparationRepository) {
          ParameterMigration.upgradeParameters(preparationRepository, ActionNewColumnToggleCommon::updateAction);
      }
focal_method.class_method_signature: ActionNewColumnToggleCommon.upgradeActions(PreparationRepository preparationRepository)
focal_method.full_signature: public static void upgradeActions(PreparationRepository preparationRepository)
focal_method.identifier: upgradeActions
focal_method.invocations: upgradeParameters
focal_method.modifiers: public static
focal_method.parameters: (PreparationRepository preparationRepository)
focal_method.return: void
focal_method.signature: void upgradeActions(PreparationRepository preparationRepository)