Skip to content

Commit 0d9e27a

Browse files
authored
doc: Remove unused imports in examples (#7924)
The "os" imports in the `tmp_path` and `tmpdir` fixture examples are unused and thus have been removed to prevent confusion.
1 parent 0cdbf8b commit 0d9e27a

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

doc/en/tmpdir.rst

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ created in the `base temporary directory`_.
2020
.. code-block:: python
2121
2222
# content of test_tmp_path.py
23-
import os
24-
2523
CONTENT = "content"
2624
2725
@@ -97,9 +95,6 @@ and more. Here is an example test usage:
9795
.. code-block:: python
9896
9997
# content of test_tmpdir.py
100-
import os
101-
102-
10398
def test_create_file(tmpdir):
10499
p = tmpdir.mkdir("sub").join("hello.txt")
105100
p.write("content")

0 commit comments

Comments
 (0)