sphinx/tests/test_util/test_util.py
2024-10-25 22:41:08 +01:00

13 lines
271 B
Python

"""Tests util functions."""
from sphinx.util.osutil import ensuredir
def test_ensuredir(tmp_path):
# Does not raise an exception for an existing directory.
ensuredir(tmp_path)
path = tmp_path / 'a' / 'b' / 'c'
ensuredir(path)
assert path.is_dir()