def test_unicode(self): self.assertIsNotNone(IS_CONTRACTION.match("Frank\u02BCs")) self.assertIsNotNone(IS_POSSESSIVE.match("Charles\u2019")) self.assertIsNotNone(IS_POSSESSIVE.match("home-less\u2032"))
def test_matches(self): self.assertIsNotNone(IS_POSSESSIVE.match("Frank's")) self.assertIsNotNone(IS_POSSESSIVE.match("Charles'"))
def test_misses(self): self.assertIsNone(IS_POSSESSIVE.match("Frank'd")) self.assertIsNone(IS_POSSESSIVE.match("s'"))