Skip to content

Commit

Permalink
Merge pull request #2 from dykov/add-after-method
Browse files Browse the repository at this point in the history
Add 'noneMatch' test case
  • Loading branch information
dykov authored May 7, 2021
2 parents 46bdebd + b59e190 commit d48fd71
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/test/java/io/github/dgroup/enumerable4j/AfterTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

import org.junit.jupiter.api.Test;
import org.llorllale.cactoos.matchers.Assertion;
import org.llorllale.cactoos.matchers.HasSize;
import org.llorllale.cactoos.matchers.HasValues;

/**
Expand Down Expand Up @@ -92,4 +93,13 @@ void allAfterFirst() {
).affirm();
}

@Test
void noneMatch() {
new Assertion<>(
"No one elements corresponds the condition, an empty collection is returned",
new Linked<>(1, 2, 3).after(n -> n < 0),
new HasSize(0)
).affirm();
}

}

0 comments on commit d48fd71

Please sign in to comment.