### Question:
OvsdbPortUpdateCommand extends AbstractTransactionCommand { @VisibleForTesting void updateInterfaceOtherConfig(final Interface interf, final OvsdbTerminationPointAugmentationBuilder ovsdbTerminationPointBuilder) { Map<String, String> interfaceOtherConfigMap = interf.getOtherConfigColumn().getData(); if (interfaceOtherConfigMap != null && !interfaceOtherConfigMap.isEmpty()) { List<InterfaceOtherConfigs> interfaceOtherConfigs = new ArrayList<>(); for (Entry<String, String> entry : interfaceOtherConfigMap.entrySet()) { String interfaceOtherConfigKeyString = entry.getKey(); String interfaceOtherConfigValueString = entry.getValue(); if (interfaceOtherConfigKeyString != null && interfaceOtherConfigValueString != null) { interfaceOtherConfigs.add(new InterfaceOtherConfigsBuilder() .setOtherConfigKey(interfaceOtherConfigKeyString) .setOtherConfigValue(interfaceOtherConfigValueString).build()); } } ovsdbTerminationPointBuilder.setInterfaceOtherConfigs(interfaceOtherConfigs); } } OvsdbPortUpdateCommand(InstanceIdentifierCodec instanceIdentifierCodec, OvsdbConnectionInstance key,
            TableUpdates updates, DatabaseSchema dbSchema); @Override void execute(ReadWriteTransaction transaction);  }### Answer:
@SuppressWarnings("unchecked") @Test public void testUpdateInterfaceOtherConfig() throws Exception { Interface interf = mock(Interface.class); Map<String, String> interfaceOtherConfigMap = new HashMap<>(); interfaceOtherConfigMap.put(OTHER_CONFIG_KEY, OTHER_CONFIG_VALUE); Column<GenericTableSchema, Map<String, String>> column = mock(Column.class); when(interf.getOtherConfigColumn()).thenReturn(column); when(column.getData()).thenReturn(interfaceOtherConfigMap); InterfaceOtherConfigsBuilder interfaceOtherConfigsBuilder = mock(InterfaceOtherConfigsBuilder.class); PowerMockito.whenNew(InterfaceOtherConfigsBuilder.class).withNoArguments() .thenReturn(interfaceOtherConfigsBuilder); when(interfaceOtherConfigsBuilder.setOtherConfigKey(anyString())).thenReturn(interfaceOtherConfigsBuilder); when(interfaceOtherConfigsBuilder.setOtherConfigValue(anyString())).thenReturn(interfaceOtherConfigsBuilder); when(interfaceOtherConfigsBuilder.build()).thenReturn(mock(InterfaceOtherConfigs.class)); OvsdbTerminationPointAugmentationBuilder ovsdbTerminationPointBuilder = mock( OvsdbTerminationPointAugmentationBuilder.class); when(ovsdbTerminationPointBuilder.setInterfaceOtherConfigs(any(List.class))) .thenReturn(ovsdbTerminationPointBuilder); Whitebox.invokeMethod(ovsdbPortUpdateCommand, "updateInterfaceOtherConfig", interf, ovsdbTerminationPointBuilder); verify(interfaceOtherConfigsBuilder).setOtherConfigKey(anyString()); verify(interfaceOtherConfigsBuilder).setOtherConfigValue(anyString()); }