test_email.py 931 Bytes
Newer Older
Nicolas Chauvat's avatar
Nicolas Chauvat committed
1
2
"""automatic tests for email views"""

3
from cubicweb.devtools.testlib import AutomaticWebTest
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
from cubicweb.devtools.fill import ValueGenerator


headers = u'''\
Return-Path: <python-projects-bounces@lists.logilab.org>
From: Benjamin Niemann <pink@odahoda.de>
To: python-projects@logilab.org
Subject: Re: [Python-projects] Pylint: Disable-msg for a block or statement?
Date: Tue, 4 Apr 2006 10:16:04 +0200
Message-Id: <200604041016.05182.pink@odahoda.de>
Sender: python-projects-bounces@lists.logilab.org

Some content'''

class EmailValueGenerator(ValueGenerator):

    def generate_Email_headers(self, entity, index):
        return headers
sylvain.thenault@logilab.fr's avatar
cleanup    
sylvain.thenault@logilab.fr committed
22

Nicolas Chauvat's avatar
Nicolas Chauvat committed
23

24
class AutomaticWebTest(AutomaticWebTest):
sylvain.thenault@logilab.fr's avatar
cleanup    
sylvain.thenault@logilab.fr committed
25

26
27
    def to_test_etypes(self):
        return set(('Email', 'EmailPart', 'EmailThread'))
sylvain.thenault@logilab.fr's avatar
cleanup    
sylvain.thenault@logilab.fr committed
28

29
30
    def list_startup_views(self):
        return ()
Nicolas Chauvat's avatar
Nicolas Chauvat committed
31
32
33
34
35


if __name__ == '__main__':
    from logilab.common.testlib import unittest_main
    unittest_main()