Skip to content

Commit 5adaf13

Browse files
committed
Test named chars x semantic level
1 parent dfd917b commit 5adaf13

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Tests/RegexTests/UTS18Tests.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,10 @@ extension UTS18Tests {
403403
XCTAssertTrue("\u{1F514}".contains(#/\N{BELL}/#))
404404
XCTAssertTrue("🐯".contains(#/\N{TIGER FACE}/#))
405405
XCTAssertFalse("🐯".contains(#/\N{TIEGR FACE}/#))
406+
407+
// Matching semantic level
408+
XCTAssertFalse("👩‍👩‍👧‍👦".contains(#/.\N{ZERO WIDTH JOINER}/#))
409+
XCTAssertTrue("👩‍👩‍👧‍👦".contains(#/(?u).\N{ZERO WIDTH JOINER}/#))
406410
}
407411

408412
func testIndividuallyNamedCharacters_XFail() {

0 commit comments

Comments
 (0)