[Zope3-checkins] CVS: Zope3/src/zope/app/browser/security/tests - test_permissionwidget.py:1.9

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


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

Modified Files:
	test_permissionwidget.py 
Log Message:

Changed to allow non-selection of a permission.

A src/zope/app/browser/services/componentpathwidget.py

Added a simple widget for displaying component paths when 
configuring components.

This widget is a bit unusual in 2 ways:

- It doesn't accept user input, because the component path
  is fixed.

- It behaves differently depending on whether the view (also field) 
  context is a configuration object or something else.




=== Zope3/src/zope/app/browser/security/tests/test_permissionwidget.py 1.8 => 1.9 ===
--- Zope3/src/zope/app/browser/security/tests/test_permissionwidget.py:1.8	Fri Mar  7 16:14:41 2003
+++ Zope3/src/zope/app/browser/security/tests/test_permissionwidget.py	Fri Mar 21 15:58:58 2003
@@ -202,6 +202,10 @@
 
         self.assertEqual(widget(), out)
 
+        request.form["field.TestName"] = ''
+
+        self.assertEqual(widget.getData(), None)
+
 
 def test_suite():
     return TestSuite((makeSuite(TestPermissionWidget),))