CVS: Products/Basket/tests - testBasket.py:1.33

Chris McDonough <[email protected]> Mon, 14 Nov 2005 09:31:36 -0500 (EST)
Newsgroups gmane.comp.web.zope.public-cvs
Message-ID <[email protected]>
Update of /cvs-repository/Products/Basket/tests
In directory cvs.zope.org:/tmp/cvs-serv14568/tests

Modified Files:
	testBasket.py 
Log Message:
Add test for a distribution that depends on a missing distribution.


=== Products/Basket/tests/testBasket.py 1.32 => 1.33 ===
--- Products/Basket/tests/testBasket.py:1.32	Fri Nov 11 15:50:29 2005
+++ Products/Basket/tests/testBasket.py	Mon Nov 14 09:31:05 2005
@@ -282,6 +282,16 @@
                          ['multiproduct1 initialized',
                           'multiproduct2 initialized'])
 
+    def test_depends_on_missing(self):
+        basket = self._makeOne()
+        basket.pre_initialized = True
+
+        sys.path.append(self.fixtures)
+        self.working_set.add_entry(self.fixtures)
+
+        self.assertRaises(pkg_resources.DistributionNotFound,
+                          basket.require, 'depends_on_missing')
+        
     def test_not_zip_safe_exploded(self):
         basket = self._makeOne()
         basket.preinitialized = False

_______________________________________________
Zope-CVS maillist  -  [email protected]
http://mail.zope.org/mailman/listinfo/zope-cvs

Zope CVS instructions: http://dev.zope.org/CVS