MCPcopy Create free account
hub / github.com/FEniCS/dolfinx / tempdir

Function tempdir

python/test/conftest.py:132–146  ·  view source on GitHub ↗

Return a unique directory name for this test function instance. Deletes and re-creates directory from previous test runs but lets the directory stay after the test run for eventual inspection. Returns the directory name, derived from the test file and function plus a sequence numbe

(request)

Source from the content-addressed store, hash-verified

130
131@pytest.fixture(scope="function")
132def tempdir(request):
133 """Return a unique directory name for this test function instance.
134
135 Deletes and re-creates directory from previous test runs but lets
136 the directory stay after the test run for eventual inspection.
137
138 Returns the directory name, derived from the test file and
139 function plus a sequence number to work with parameterized tests.
140
141 Does NOT change the current directory.
142
143 MPI safe (assuming MPI.COMM_WORLD context).
144
145 """
146 return _create_tempdir(request)
147
148
149@pytest.fixture(scope="function", autouse=True)

Callers

nothing calls this directly

Calls 1

_create_tempdirFunction · 0.85

Tested by

no test coverage detected