예제 #1
0
파일: tests.py 프로젝트: pasala91/test
    def test_get_from_email_domain(self):
        with self.options({"mail.from": "*****@*****.**"}):
            assert get_from_email_domain() == "example.com"

        with self.options({"mail.from": "root@localhost"}):
            assert get_from_email_domain() == "localhost"

        with self.options({"mail.from": "garbage"}):
            assert get_from_email_domain() == "garbage"
예제 #2
0
    def test_get_from_email_domain(self):
        with self.options({'mail.from': '*****@*****.**'}):
            assert get_from_email_domain() == 'example.com'

        with self.options({'mail.from': 'root@localhost'}):
            assert get_from_email_domain() == 'localhost'

        with self.options({'mail.from': 'garbage'}):
            assert get_from_email_domain() == 'garbage'
예제 #3
0
파일: tests.py 프로젝트: Kayle009/sentry
    def test_get_from_email_domain(self):
        with self.options({'mail.from': '*****@*****.**'}):
            assert get_from_email_domain() == 'example.com'

        with self.options({'mail.from': 'root@localhost'}):
            assert get_from_email_domain() == 'localhost'

        with self.options({'mail.from': 'garbage'}):
            assert get_from_email_domain() == 'garbage'