def test_invalidEmail(self): self.assertEqual(False, ipavalidate.Email("test")) self.assertEqual(False, ipavalidate.Email("test@freeipa")) self.assertEqual(False, ipavalidate.Email("[email protected]")) self.assertEqual(False, ipavalidate.Email("")) self.assertEqual(False, ipavalidate.Email(None))
def test_invalidEmail(self): assert ipavalidate.Email("test") is False assert ipavalidate.Email("test@freeipa") is False assert ipavalidate.Email("[email protected]") is False assert ipavalidate.Email("") is False assert ipavalidate.Email(None) is False
def test_validEmail(self): self.assertEqual(True, ipavalidate.Email("*****@*****.**")) self.assertEqual(True, ipavalidate.Email("", notEmpty=False))
def test_validEmail(self): assert ipavalidate.Email("*****@*****.**") is True assert ipavalidate.Email("", notEmpty=False) is True