@Test
void should_MatchSortDirectionForEachSortBy_When_MapContainsMultipleSortByAndOrderBy()
    throws Exception {

  MultiValueMap<String, String> map = new LinkedMultiValueMap<>();
  map.put(QueryHelper.SORT_BY, Arrays.asList("sort-by-value1", "sort-by-value2"));
  map.put(QueryHelper.ORDER_DIRECTION, Arrays.asList("desc", "asc"));
  MockBiConsumer consumer = mock(MockBiConsumer.class);
  applyAndRemoveSortingParams(map, consumer);
  verify(consumer).accept("sort-by-value1", SortDirection.DESCENDING);
  verify(consumer).accept("sort-by-value2", SortDirection.ASCENDING);
  verifyNoMoreInteractions(consumer);
}