Ejemplo n.º 1
0
 def test_short_list_id(self):
     """Some mailing lists have List-Id headers in short formats, where it
        is only the list ID itself (without enclosing angle-brackets). """
     email = MIMEText('')
     email['List-Id'] = self.project.listid
     project = find_project_by_header(email)
     self.assertEqual(project, self.project)
Ejemplo n.º 2
0
 def test_short_list_id(self):
     """Some mailing lists have List-Id headers in short formats, where it
        is only the list ID itself (without enclosing angle-brackets). """
     email = MIMEText('')
     email['List-Id'] = self.project.listid
     project = find_project_by_header(email)
     self.assertEqual(project, self.project)
Ejemplo n.º 3
0
 def test_long_list_id(self):
     email = MIMEText('')
     email['List-Id'] = 'Test text <%s>' % self.project.listid
     project = find_project_by_header(email)
     self.assertEqual(project, self.project)
Ejemplo n.º 4
0
 def test_substring_list_id(self):
     email = MIMEText('')
     email['List-Id'] = 'example.com'
     project = find_project_by_header(email)
     self.assertEqual(project, None)
Ejemplo n.º 5
0
 def test_whitespace_list_id(self):
     email = MIMEText('')
     email['List-Id'] = ' '
     project = find_project_by_header(email)
     self.assertEqual(project, None)
Ejemplo n.º 6
0
 def test_no_list_id(self):
     email = MIMEText('')
     project = find_project_by_header(email)
     self.assertEqual(project, None)
Ejemplo n.º 7
0
 def test_long_list_id(self):
     email = MIMEText('')
     email['List-Id'] = 'Test text <%s>' % self.project.listid
     project = find_project_by_header(email)
     self.assertEqual(project, self.project)
Ejemplo n.º 8
0
 def test_substring_list_id(self):
     email = MIMEText('')
     email['List-Id'] = 'example.com'
     project = find_project_by_header(email)
     self.assertEqual(project, None)
Ejemplo n.º 9
0
 def test_whitespace_list_id(self):
     email = MIMEText('')
     email['List-Id'] = ' '
     project = find_project_by_header(email)
     self.assertEqual(project, None)
Ejemplo n.º 10
0
 def test_no_list_id(self):
     email = MIMEText('')
     project = find_project_by_header(email)
     self.assertEqual(project, None)