예제 #1
0
    def test_10(self):
        """
        Test Case 10:
        Test :py:meth:`magrathea.utils.file.File._check_dir_exists` with a non-existing directory.

        Test is passed if return value is False.
        """
        self.assertFalse(File._check_dir_exists('/foobarstuffdirdoesntexist'))
예제 #2
0
    def test_11(self):
        """
        Test Case 11:
        Test :py:meth:`magrathea.utils.file.File._check_dir_exists` with an existing fs object not being a directory.

        Test is passed if return value is False.
        """
        self.assertFalse(File._check_dir_exists(__file__))
예제 #3
0
    def test_09(self):
        """
        Test Case 09:
        Test :py:meth:`magrathea.utils.file.File._check_dir_exists` with an existing directory (this file's parent).

        Test is passed if return value is True.
        """
        self.assertTrue(File._check_dir_exists(os.path.dirname(__file__)))