예제 #1
0
 def test_good_dir(self):
     os.makedirs('test_dir')
     self.assertTrue(cli.validate_path('test_dir'))
     os.rmdir('test_dir')
예제 #2
0
 def test_good_file(self):
     write_tmp_file("test_file","")
     self.assertTrue(cli.validate_path('test_file'))
     os.remove("test_file")
예제 #3
0
 def test_bad_dir(self):
     self.assertFalse(cli.validate_path('/dirthatdoesntexist/'))
예제 #4
0
 def test_bad_file(self):
     self.assertFalse(cli.validate_path('/filethatdoesntexist'))