(String regex, String string,
String... matches)
| 33 | } |
| 34 | |
| 35 | private static void expectFind(String regex, String string, |
| 36 | String... matches) |
| 37 | { |
| 38 | Matcher matcher = getMatcher(regex, string); |
| 39 | int i = 0; |
| 40 | while (i < matches.length) { |
| 41 | expect(matcher.find()); |
| 42 | expect(matches[i++].equals(matcher.group())); |
| 43 | } |
| 44 | expect(!matcher.find()); |
| 45 | } |
| 46 | |
| 47 | private static void expectSplit(String regex, String string, |
| 48 | String... list) |