Anonymous committed 072710c

Added metadat info for fake dists' grammar and towel-stuff. This allows the get_distributions test to pass.

Comments (0)

Files changed (3)


+Metadata-Version: 1.2
+Name: grammar
+Version: 1.0a4


+Metadata-Version: 1.2
+Name: towel-stuff
+Version: 0.1


     def test_get_distributions(self):
         """Lookup all distributions found in the ``sys.path``."""
         # This test could potentially pick up other installed distributions
-        fake_dists = [('grammar', '1.0a4'), ('choxie', '2009'),
+        fake_dists = [('grammar', '1.0a4'), ('choxie', ''),
             ('towel-stuff', '0.1')]
         found_dists = []
       "item received was not a Distribution instance: "
                     "%s" % type(dist))
             if in dict(fake_dists).keys():
-                found_dists.append((, dist.metadata.version,))
+                found_dists.append((, dist.metadata['version'],))
             # otherwise we don't care what other distributions are found
         # Finally, test that we found all that we were looking for
-        self.assertListEqual(found_dists, dict(fake_dists).keys())
+        self.assertListEqual(sorted(found_dists), sorted(fake_dists))