@@ -20,27 +20,27 @@ public IsIterableContainingInOrder(List<Matcher<? super E>> matchers) {
20
20
21
21
@ Override
22
22
protected boolean matchesSafely (Iterable <? extends E > iterable , Description mismatchDescription ) {
23
- final MatchSeries <E > matchSeries = new MatchSeries <>(matchers , mismatchDescription );
23
+ final MatchInOrder <E > inOrder = new MatchInOrder <>(matchers , mismatchDescription );
24
24
for (E item : iterable ) {
25
- if (!matchSeries .matches (item )) {
25
+ if (!inOrder .matches (item )) {
26
26
return false ;
27
27
}
28
28
}
29
29
30
- return matchSeries .isFinished ();
30
+ return inOrder .isFinished ();
31
31
}
32
32
33
33
@ Override
34
34
public void describeTo (Description description ) {
35
35
description .appendText ("iterable containing " ).appendList ("[" , ", " , "]" , matchers );
36
36
}
37
37
38
- private static class MatchSeries <F > {
38
+ private static class MatchInOrder <F > {
39
39
private final List <Matcher <? super F >> matchers ;
40
40
private final Description mismatchDescription ;
41
41
private int nextMatchIx = 0 ;
42
42
43
- public MatchSeries (List <Matcher <? super F >> matchers , Description mismatchDescription ) {
43
+ public MatchInOrder (List <Matcher <? super F >> matchers , Description mismatchDescription ) {
44
44
this .mismatchDescription = mismatchDescription ;
45
45
if (matchers .isEmpty ()) {
46
46
throw new IllegalArgumentException ("Should specify at least one expected element" );
0 commit comments