def test_smtp_logout(smtp_server_config): srv = SMTPServer(**smtp_server_config) srv.login() srv.logout() assert srv.is_login() is False and srv._login is False
def test_smtp_duplicate_login(smtp_server_config): srv = SMTPServer(**smtp_server_config) srv.login() srv.login() assert srv.is_login() is True and srv._login is True srv.logout()