Exemple #1
0
 def test_get_dirpath(self):
     tempdir = tempfile.mkdtemp()
     try:
         config = Configuration(properties={'somepkg.home': tempdir})
         self.assertEqual(tempdir, config.get_dirpath('somepkg.home'))
     finally:
         os.rmdir(tempdir)
Exemple #2
0
 def test_get_dirpath(self):
     tempdir = tempfile.mkdtemp()
     try:
         config = Configuration(properties={'somepkg.home': tempdir})
         self.assertEqual(tempdir, config.get_dirpath('somepkg.home'))
     finally:
         os.rmdir(tempdir)
Exemple #3
0
 def test_get_dirpath_non_existant(self):
     tempdir = tempfile.mkdtemp()
     os.rmdir(tempdir)
     config = Configuration(properties={'somepkg.home': tempdir})
     self.assertEqual(None, config.get_dirpath('somepkg.home'))
Exemple #4
0
 def test_get_dirpath_non_existant(self):
     tempdir = tempfile.mkdtemp()
     os.rmdir(tempdir)
     config = Configuration(properties={'somepkg.home': tempdir})
     self.assertEqual(None, config.get_dirpath('somepkg.home'))