def test_type_all_type(self): type_ = FullType("ALL@cat") self.assertTrue(type_.match(Component("foo#bar@cat"))) self.assertTrue(type_.match(Component("foo#baz@cat"))) self.assertFalse(type_.match(Component("fuu#bar@another")))
def test_type_normal(self): type_ = FullType("bar@cat") self.assertTrue(type_.match(Component("foo#bar@cat"))) self.assertFalse(type_.match(Component("foo#baz@cat"))) self.assertFalse(type_.match(Component("foo#bar@caz"))) self.assertFalse(type_.match(Component("foo#baz@caz")))
def test_type_all(self): type_ = FullType("ALL") self.assertTrue(type_.match(Component("foo#bar@cat")))