Skip to content

Commit

Permalink
Sort alphabetically if count is false (#300)
Browse files Browse the repository at this point in the history
  • Loading branch information
fsteeg committed May 12, 2023
1 parent 4d8bdbf commit 4b0a8f3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,9 @@ private TripleCount tripleCount() {

private TripleSort tripleSort() {
final TripleSort tripleSort = new TripleSort();
tripleSort.setNumeric(true);
tripleSort.setNumeric(count);
tripleSort.setBy(Compare.OBJECT);
tripleSort.setOrder(Order.DECREASING);
tripleSort.setOrder(count ? Order.DECREASING : Order.INCREASING);
return tripleSort;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ public void testShouldListPaths() {
public void testShouldListPathsNoCount() {
lister.setCount(false);
verify(
"c.*",
"a",
"b.*",
"a");
"c.*");
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,9 @@ public void testShouldListPathsDontCount() {
lister = new MetafixListValues("c");
lister.setCount(false);
verify(
"cC",
"cA",
"cB");
"cB",
"cC");
}

private void processRecord() {
Expand Down

0 comments on commit 4b0a8f3

Please sign in to comment.