Commit b7948630 authored by Nicolas Delaby's avatar Nicolas Delaby

revert r41130, i was wrong

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@41133 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0a95ff02
...@@ -101,9 +101,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional): ...@@ -101,9 +101,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
mfrom, mto, message_text = last_message mfrom, mto, message_text = last_message
self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0]) self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0])
mail_message = email.message_from_string(message_text) mail_message = email.message_from_string(message_text)
failed = True
for part in mail_message.walk(): for part in mail_message.walk():
failed = False
content_type = part.get_content_type() content_type = part.get_content_type()
file_name = part.get_filename() file_name = part.get_filename()
# "History" is the title of Base_viewHistory form # "History" is the title of Base_viewHistory form
...@@ -117,7 +115,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional): ...@@ -117,7 +115,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
if error_list: if error_list:
self.fail(''.join(error_list)) self.fail(''.join(error_list))
break break
if failed: else:
self.fail('Attachment not found in email') self.fail('Attachment not found in email')
def test_normal_form(self): def test_normal_form(self):
...@@ -138,9 +136,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional): ...@@ -138,9 +136,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
mfrom, mto, message_text = last_message mfrom, mto, message_text = last_message
self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0]) self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0])
mail_message = email.message_from_string(message_text) mail_message = email.message_from_string(message_text)
failed = True
for part in mail_message.walk(): for part in mail_message.walk():
failed = False
content_type = part.get_content_type() content_type = part.get_content_type()
file_name = part.get_filename() file_name = part.get_filename()
# "Person" is the title of Person_view form # "Person" is the title of Person_view form
...@@ -154,7 +150,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional): ...@@ -154,7 +150,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
if error_list: if error_list:
self.fail(''.join(error_list)) self.fail(''.join(error_list))
break break
if failed: else:
self.fail('Attachment not found in email') self.fail('Attachment not found in email')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment