[Zope-Checkins] CVS: Zope3/lib/python/Zope/Configuration/tests - testNames.py:1.1.2.6
Jim Fulton
jim@zope.com
Tue, 12 Feb 2002 15:29:31 -0500
Update of /cvs-repository/Zope3/lib/python/Zope/Configuration/tests
In directory cvs.zope.org:/tmp/cvs-serv11482/tests
Modified Files:
Tag: Zope-3x-branch
testNames.py
Log Message:
Fixed bug: name resolving names without dots failed
=== Zope3/lib/python/Zope/Configuration/tests/testNames.py 1.1.2.5 => 1.1.2.6 ===
from Zope.Configuration.tests import Products_
- self.old=sys.modules.get('Products', None)
+ self.old=sys.modules.get('ZopeProducts', None)
sys.modules['ZopeProducts']=Products_
def tearDown(self):
@@ -36,7 +36,12 @@
c=resolve('Zope.Configuration.tests.Contact.Contact.Contact')
self.assertEquals(c.n, 1)
+ def testNoDots(self):
+ from Zope.Configuration.name import resolve
+ import Zope
+ c=resolve('Zope')
+ self.assertEquals(id(c), id(Zope))
def test_suite():
loader=unittest.TestLoader()