[Zope-Checkins] CVS: Zope3/lib/python/Zope/App/OFS/Container/Views/Browser/tests - testContents.py:1.3

Jim Fulton jim@zope.com
Thu, 13 Jun 2002 19:16:11 -0400


Update of /cvs-repository/Zope3/lib/python/Zope/App/OFS/Container/Views/Browser/tests
In directory cvs.zope.org:/tmp/cvs-serv10697/lib/python/Zope/App/OFS/Container/Views/Browser/tests

Modified Files:
	testContents.py 
Log Message:
Got icons working, and, along the way:

- Implemented the icon directive

- Implemented
  http://dev.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/ResourcesProposal

- Added a special view, named '', for service manager containers that
  allows resources to have URLs like:

  http://foo.com/@@/resourcename

- Fixed some server code that caused HTTP response data to get
  promoted to unicode

- Updated the folder contents page to display icons.

- Ported icons for folder, file, image, and zptpage. Many more icons
  need to be ported or created.



=== Zope3/lib/python/Zope/App/OFS/Container/Views/Browser/tests/testContents.py 1.2 => 1.3 ===
 
 from unittest import TestCase, TestSuite, main, makeSuite
-from Zope.Testing.CleanUp import CleanUp # Base class w registry cleanup
+from Zope.ComponentArchitecture.tests.PlacelessSetup import PlacelessSetup
 
-class BaseTestContentsBrowserView:
+class BaseTestContentsBrowserView(PlacelessSetup):
     """Base class for testing browser contents.
 
     Subclasses need to define a method, '_TestView__newContext', that
@@ -100,7 +100,8 @@
 
     def _TestView__newView(self, container):
         from Zope.App.OFS.Container.Views.Browser.Contents import Contents
-        return Contents(container, None)
+        from Zope.Publisher.Browser.BrowserRequest import TestRequest
+        return Contents(container, TestRequest())
 
 def test_suite():
     return TestSuite((