diff options
author | Luis Pabon <lpabon@redhat.com> | 2013-07-09 15:41:43 -0400 |
---|---|---|
committer | Peter Portante <pportant@redhat.com> | 2013-07-09 18:20:05 -0700 |
commit | 3f72ae45a38b40dc0ff718e9cea91f18bb9bb7f0 (patch) | |
tree | 8f3f70dc72744b645cc5172f1f2de0c8bfd6797d /test | |
parent | 9282f7095ed61d79d9232f7b2c6f7e838117beca (diff) |
Remove do_mkdir and simplify mkdirs
Change-Id: I2e629533bceafb341ced5b1b3f2436448293e03f
Signed-off-by: Luis Pabon <lpabon@redhat.com>
Reviewed-on: http://review.gluster.org/5304
Reviewed-by: Peter Portante <pportant@redhat.com>
Tested-by: Peter Portante <pportant@redhat.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/unit/common/test_fs_utils.py | 25 |
1 files changed, 3 insertions, 22 deletions
diff --git a/test/unit/common/test_fs_utils.py b/test/unit/common/test_fs_utils.py index b31a9a2..910199e 100644 --- a/test/unit/common/test_fs_utils.py +++ b/test/unit/common/test_fs_utils.py @@ -116,32 +116,13 @@ class TestFsUtils(unittest.TestCase): os.close(fd) os.remove(tmpfile) - def test_do_mkdir(self): - try: - path = os.path.join('/tmp', str(random.random())) - fs.do_mkdir(path) - assert os.path.exists(path) - assert fs.do_mkdir(path) - finally: - os.rmdir(path) - - def test_do_mkdir_err(self): - try: - path = os.path.join('/tmp', str(random.random()), str(random.random())) - fs.do_mkdir(path) - except OSError: - pass - else: - self.fail("OSError expected") - - - def test_do_makedirs(self): + def test_mkdirs(self): try: subdir = os.path.join('/tmp', str(random.random())) path = os.path.join(subdir, str(random.random())) - fs.do_makedirs(path) + fs.mkdirs(path) assert os.path.exists(path) - assert fs.do_makedirs(path) + assert fs.mkdirs(path) finally: shutil.rmtree(subdir) |