Skip to content

Commit 0b18e0f

Browse files
committed
Merge pull request #1 from xebia-france/master
test macintosh line break
2 parents 6c9de13 + 66ebfb5 commit 0b18e0f

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

src/test/java/ru/lanwen/verbalregex/BasicFunctionalityUnitTest.java

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,18 @@ public void testLineBreak() {
178178
assertThat("abc then line break then space then def", testRegex, not(matchesTo("abc\r\n def")));
179179
}
180180

181+
@Test
182+
public void testMacintoshLineBreak() {
183+
VerbalExpression testRegex = new VerbalExpression.Builder()
184+
.startOfLine()
185+
.then("abc")
186+
.lineBreak()
187+
.then("def")
188+
.build();
189+
190+
assertThat("abc then line break then def", testRegex, matchesTo("abc\r\rdef"));
191+
}
192+
181193
@Test
182194
public void testBr() {
183195
VerbalExpression testRegexBr = new VerbalExpression.Builder()

0 commit comments

Comments
 (0)