From b7948630226289f1930a22933dc905edd70ffbbf Mon Sep 17 00:00:00 2001
From: Nicolas Delaby <nicolas@nexedi.com>
Date: Sun, 5 Dec 2010 09:48:00 +0000
Subject: [PATCH] revert r41130, i was wrong

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@41133 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5OOo/tests/testDeferredStyle.py | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/product/ERP5OOo/tests/testDeferredStyle.py b/product/ERP5OOo/tests/testDeferredStyle.py
index c5b2c0be67..18045b5a8e 100644
--- a/product/ERP5OOo/tests/testDeferredStyle.py
+++ b/product/ERP5OOo/tests/testDeferredStyle.py
@@ -101,9 +101,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
     mfrom, mto, message_text = last_message
     self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0])
     mail_message = email.message_from_string(message_text)
-    failed = True
     for part in mail_message.walk():
-      failed = False
       content_type = part.get_content_type()
       file_name = part.get_filename()
       # "History" is the title of Base_viewHistory form
@@ -117,7 +115,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
         if error_list:
           self.fail(''.join(error_list))
         break
-    if failed:
+    else:
       self.fail('Attachment not found in email')
 
   def test_normal_form(self):
@@ -138,9 +136,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
     mfrom, mto, message_text = last_message
     self.assertEquals('"%s" <%s>' % (self.first_name, self.recipient_email_address), mto[0])
     mail_message = email.message_from_string(message_text)
-    failed = True
     for part in mail_message.walk():
-      failed = False
       content_type = part.get_content_type()
       file_name = part.get_filename()
       # "Person" is the title of Person_view form
@@ -154,7 +150,7 @@ class TestDeferredStyle(ERP5TypeTestCase, ZopeTestCase.Functional):
         if error_list:
           self.fail(''.join(error_list))
         break
-    if failed:
+    else:
       self.fail('Attachment not found in email')
 
 
-- 
2.30.9