コード例 #1
0
 def test_get_uniqueext_second(self):
     """
     Test get_uniqueext() with one collision
     """
     with tempfile.TemporaryDirectory() as tmpd:
         os.mkdir(os.path.join(tmpd, "test-pkg"))
         self.assertEqual(build.get_uniqueext(tmpd, "test", "pkg"), "pkg-1")
コード例 #2
0
 def test_get_uniqueext_first(self):
     """
     Test get_uniqueext() with no collisions
     """
     with tempfile.TemporaryDirectory() as tmpd:
         self.assertEqual(build.get_uniqueext(tmpd, "test", "pkg"), "pkg")