[Zope3-checkins] CVS: Zope3/src/zope/app/browser/form/tests - test_editview.py:1.6

Jim Fulton jim@zope.com
Fri, 21 Mar 2003 15:57:45 -0500


Update of /cvs-repository/Zope3/src/zope/app/browser/form/tests
In directory cvs.zope.org:/tmp/cvs-serv18272/src/zope/app/browser/form/tests

Modified Files:
	test_editview.py 
Log Message:
Changed so that multiple calls to update are ignored.  

This is useful because it let us add an extra call to the top of
full-page the template so that updates are applied before standard
look and feel is rendered. This means that standard elements like tabs
and modification times can reflect changes.




=== Zope3/src/zope/app/browser/form/tests/test_editview.py 1.5 => 1.6 ===
--- Zope3/src/zope/app/browser/form/tests/test_editview.py:1.5	Thu Mar 13 13:49:03 2003
+++ Zope3/src/zope/app/browser/form/tests/test_editview.py	Fri Mar 21 15:57:44 2003
@@ -154,6 +154,19 @@
         self.assertEqual(c.b  , None)
         self.assertEqual(c.baz, u'r baz')
 
+        # Verify that calling update multiple times has no effect
+
+        c.__dict__.clear()
+        self.assertEqual(v.update(), message)
+        self.assertEqual(c.foo, u'c foo')
+        self.assertEqual(c.bar, u'c bar')
+        self.assertEqual(c.a  , u'c a')
+        self.assertEqual(c.b  , u'c b')
+        self.assertEqual(c.baz, u'c baz')
+
+        
+
+
 def test_suite():
     return TestSuite((
         makeSuite(Test),