[Zope3-checkins] SVN: Zope3/trunk/ - fix up packaging info for
zope.testbrowser
Benji York
benji at zope.com
Sat Feb 18 15:49:44 EST 2006
Log message for revision 41673:
- fix up packaging info for zope.testbrowser
- deprecate importing Browser from zope.testbrowser
(use zope.testbrowser.testing instead)
- fix deprecation warnings created by above
Changed:
U Zope3/trunk/releases/ZopeTestbrowser.cfg
U Zope3/trunk/src/zope/app/apidoc/browser/README.txt
U Zope3/trunk/src/zope/app/apidoc/codemodule/browser/introspector.txt
U Zope3/trunk/src/zope/app/boston/README.txt
U Zope3/trunk/src/zope/app/wsgi/tests.py
U Zope3/trunk/src/zope/testbrowser/README.txt
U Zope3/trunk/src/zope/testbrowser/__init__.py
-=-
Modified: Zope3/trunk/releases/ZopeTestbrowser.cfg
===================================================================
--- Zope3/trunk/releases/ZopeTestbrowser.cfg 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/releases/ZopeTestbrowser.cfg 2006-02-18 20:49:44 UTC (rev 41673)
@@ -8,4 +8,8 @@
<exclude>
zope.app
zope.interface
+ pullparser
+ ClientCookie
+ ClientForm
+ mechanize
</exclude>
Modified: Zope3/trunk/src/zope/app/apidoc/browser/README.txt
===================================================================
--- Zope3/trunk/src/zope/app/apidoc/browser/README.txt 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/app/apidoc/browser/README.txt 2006-02-18 20:49:44 UTC (rev 41673)
@@ -4,7 +4,7 @@
Get a browser started:
- >>> from zope.testbrowser import Browser
+ >>> from zope.testbrowser.testing import Browser
>>> browser = Browser()
>>> browser.addHeader('Authorization', 'Basic mgr:mgrpw')
Modified: Zope3/trunk/src/zope/app/apidoc/codemodule/browser/introspector.txt
===================================================================
--- Zope3/trunk/src/zope/app/apidoc/codemodule/browser/introspector.txt 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/app/apidoc/codemodule/browser/introspector.txt 2006-02-18 20:49:44 UTC (rev 41673)
@@ -6,7 +6,7 @@
obejct, the context of the introspector view. When in `devmode`, the
introspector is simply available as follows:
- >>> from zope.testbrowser import Browser
+ >>> from zope.testbrowser.testing import Browser
>>> browser = Browser()
>>> browser.addHeader('Authorization', 'Basic mgr:mgrpw')
>>> browser.handleErrors = False
Modified: Zope3/trunk/src/zope/app/boston/README.txt
===================================================================
--- Zope3/trunk/src/zope/app/boston/README.txt 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/app/boston/README.txt 2006-02-18 20:49:44 UTC (rev 41673)
@@ -5,7 +5,7 @@
The Boston skin is a new UI for the Zope Management Interface called ZMI.
Feel free to write comments, ideas and wishes to the zope3-dev mailinglist.
- >>> from zope.testbrowser import Browser
+ >>> from zope.testbrowser.testing import Browser
>>> browser = Browser()
>>> browser.addHeader('Authorization', 'Basic mgr:mgrpw')
>>> browser.handleErrors = False
Modified: Zope3/trunk/src/zope/app/wsgi/tests.py
===================================================================
--- Zope3/trunk/src/zope/app/wsgi/tests.py 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/app/wsgi/tests.py 2006-02-18 20:49:44 UTC (rev 41673)
@@ -65,7 +65,7 @@
... checker.NamesChecker(['browserDefault', '__call__']),
... )
- >>> from zope.testbrowser import Browser
+ >>> from zope.testbrowser.testing import Browser
>>> browser = Browser()
>>> browser.handleErrors = False
>>> browser.open('http://localhost/@@test-file-view.html')
Modified: Zope3/trunk/src/zope/testbrowser/README.txt
===================================================================
--- Zope3/trunk/src/zope/testbrowser/README.txt 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/testbrowser/README.txt 2006-02-18 20:49:44 UTC (rev 41673)
@@ -13,9 +13,9 @@
There is also a special version of the ``Browser`` class used to do functional
testing of Zope 3 applications, it can be imported from
-``zope.testbrowser.testing`` or just ``zope.testbrowser`` directly:
+``zope.testbrowser.testing``:
- >>> from zope.testbrowser import Browser
+ >>> from zope.testbrowser.testing import Browser
>>> browser = Browser()
The browser can send arbitrary headers; this is helpful for setting the
Modified: Zope3/trunk/src/zope/testbrowser/__init__.py
===================================================================
--- Zope3/trunk/src/zope/testbrowser/__init__.py 2006-02-18 19:05:59 UTC (rev 41672)
+++ Zope3/trunk/src/zope/testbrowser/__init__.py 2006-02-18 20:49:44 UTC (rev 41673)
@@ -16,4 +16,14 @@
$Id$
"""
-from testing import Browser
+from zope.deprecation import deprecated
+
+try:
+ from testing import Browser
+ deprecated('Browser',
+ 'importing Browser from zope.interface has been deprecated and will'
+ ' be removed in 3.5; import Browser from zope.browser.testing instead')
+except ImportError:
+ # This is really ugly, but non-Zope code needs to be able to import this
+ # and the testing module depends on Zope 3
+ pass
More information about the Zope3-Checkins
mailing list