test_sendable_email.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:django-email-pal 作者: 18F 项目源码 文件源码
def test_non_sendable_email_raises_improperly_configured_error():
    with pytest.raises(ImproperlyConfigured):
        with override_settings(SENDABLE_EMAILS=['unittest.TestCase']):
            pass  # pragma: no cover
    # This is weird, but required for the next test to not explode.
    # I think b/c the former exception was raised in a way that "broke"
    # override_settings, preventing it from restoring the old value.
    delattr(settings, 'SENDABLE_EMAILS')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号