[Python-checkins] distutils2: Added a repr test for depgraph

tarek.ziade python-checkins at python.org
Sun Jan 23 15:48:23 CET 2011


tarek.ziade pushed 7036f288b82d to distutils2:

http://hg.python.org/distutils2/rev/7036f288b82d
changeset:   884:7036f288b82d
user:        Antoine Reversat <a.reversat at gmail.com>
date:        Wed Dec 08 23:40:37 2010 -0500
summary:
  Added a repr test for depgraph

files:
  distutils2/tests/test_depgraph.py

diff --git a/distutils2/tests/test_depgraph.py b/distutils2/tests/test_depgraph.py
--- a/distutils2/tests/test_depgraph.py
+++ b/distutils2/tests/test_depgraph.py
@@ -274,6 +274,16 @@
 
         self.checkLists(matches, expected)
 
+    def test_repr(self):
+        dists = []
+        for name in self.DISTROS_DIST + self.DISTROS_EGG + self.BAD_EGGS:
+            dist = pkgutil.get_distribution(name, use_egg_info=True)
+            self.assertNotEqual(dist, None)
+            dists.append(dist)
+
+        graph = depgraph.generate_graph(dists)
+        assert repr(graph)
+
     def test_main(self):
         tempout = StringIO.StringIO()
         old = sys.stdout

--
Repository URL: http://hg.python.org/distutils2


More information about the Python-checkins mailing list