@Test public void testDoChangeShouldNotMoveTheFirstStubConfigurationToUpByOne() { String[] expectedGroupnames = normalStubDescriptors.keySet().toArray(new String[normalStubDescriptors.size()]); underTest = new ChangeOrderCommand(1, GROUPNAME_FIRST, request, urlAccessLogMessageAssembler); Map<String, StubDescriptor> result = underTest.modify(normalStubDescriptors); String[] resultGroupnames = result.keySet().toArray(new String[result.size()]); Assert.assertEquals(resultGroupnames, expectedGroupnames); }
@Override public Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors) { Map<String, StubDescriptor> updated; updated = doTheMoving(direction, groupName, stubDescriptors, request); return updated; }
ChangeOrderCommand implements StubDescriptorModificationCommand { @Override public Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors) { Map<String, StubDescriptor> updated; updated = doTheMoving(direction, groupName, stubDescriptors, request); return updated; } }
ChangeOrderCommand implements StubDescriptorModificationCommand { @Override public Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors) { Map<String, StubDescriptor> updated; updated = doTheMoving(direction, groupName, stubDescriptors, request); return updated; } ChangeOrderCommand(final int direction, final String groupName, final HttpServletRequest request, final UrlAccessLogMessageAssembler urlAccessLogMessageAssembler); }
ChangeOrderCommand implements StubDescriptorModificationCommand { @Override public Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors) { Map<String, StubDescriptor> updated; updated = doTheMoving(direction, groupName, stubDescriptors, request); return updated; } ChangeOrderCommand(final int direction, final String groupName, final HttpServletRequest request, final UrlAccessLogMessageAssembler urlAccessLogMessageAssembler); @Override Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors); String getGroupName(); HttpServletRequest getRequest(); int getDirection(); }
ChangeOrderCommand implements StubDescriptorModificationCommand { @Override public Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors) { Map<String, StubDescriptor> updated; updated = doTheMoving(direction, groupName, stubDescriptors, request); return updated; } ChangeOrderCommand(final int direction, final String groupName, final HttpServletRequest request, final UrlAccessLogMessageAssembler urlAccessLogMessageAssembler); @Override Map<String, StubDescriptor> modify(Map<String, StubDescriptor> stubDescriptors); String getGroupName(); HttpServletRequest getRequest(); int getDirection();  }