Пример #1
0
 def test_dfs_present(self):
     '''
     Test for Check if a file or directory is present on the distributed FS.
     '''
     with patch.object(hadoop, '_hadoop_cmd',
                       side_effect=['No such file or directory', 'A']):
         self.assertFalse(hadoop.dfs_present('path'))
         self.assertTrue(hadoop.dfs_present('path'))
Пример #2
0
 def test_dfs_present(self):
     '''
     Test for Check if a file or directory is present on the distributed FS.
     '''
     with patch.object(hadoop,
                       '_hadoop_cmd',
                       side_effect=['No such file or directory', 'A']):
         self.assertFalse(hadoop.dfs_present('path'))
         self.assertTrue(hadoop.dfs_present('path'))
Пример #3
0
 def test_dfs_present(self):
     """
     Test for Check if a file or directory is present on the distributed FS.
     """
     with patch.object(hadoop,
                       "_hadoop_cmd",
                       side_effect=["No such file or directory", "A"]):
         self.assertFalse(hadoop.dfs_present("path"))
         self.assertTrue(hadoop.dfs_present("path"))