summaryrefslogtreecommitdiff
path: root/src/_pytest/tmpdir.py
diff options
context:
space:
mode:
authorBruno Oliveira <nicoddemus@gmail.com>2019-07-09 19:04:06 -0300
committerGitHub <noreply@github.com>2019-07-09 19:04:06 -0300
commit31738155b578d8dfa3be3359d1f4a990a3b52177 (patch)
treed0b68279fa176d3420f0390c2be26bf4f71994ec /src/_pytest/tmpdir.py
parent39a43dbae16d0f111ee4f818e458d57e55b4d3da (diff)
parentdfe54cd82f55f17f3c9e6e078325f306a046b93b (diff)
downloadpytest-31738155b578d8dfa3be3359d1f4a990a3b52177.tar.gz
Remove deprecated features (#5529)
Remove deprecated features
Diffstat (limited to 'src/_pytest/tmpdir.py')
-rw-r--r--src/_pytest/tmpdir.py15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/_pytest/tmpdir.py b/src/_pytest/tmpdir.py
index 48680c07e..123a583ad 100644
--- a/src/_pytest/tmpdir.py
+++ b/src/_pytest/tmpdir.py
@@ -2,7 +2,6 @@
import os
import re
import tempfile
-import warnings
import attr
import py
@@ -88,19 +87,6 @@ class TempdirFactory:
_tmppath_factory = attr.ib()
- def ensuretemp(self, string, dir=1):
- """ (deprecated) return temporary directory path with
- the given string as the trailing part. It is usually
- better to use the 'tmpdir' function argument which
- provides an empty unique-per-test-invocation directory
- and is guaranteed to be empty.
- """
- # py.log._apiwarn(">1.1", "use tmpdir function argument")
- from .deprecated import PYTEST_ENSURETEMP
-
- warnings.warn(PYTEST_ENSURETEMP, stacklevel=2)
- return self.getbasetemp().ensure(string, dir=dir)
-
def mktemp(self, basename, numbered=True):
"""Create a subdirectory of the base temporary directory and return it.
If ``numbered``, ensure the directory is unique by adding a number
@@ -138,7 +124,6 @@ def pytest_configure(config):
config._cleanup.append(mp.undo)
mp.setattr(config, "_tmp_path_factory", tmppath_handler, raising=False)
mp.setattr(config, "_tmpdirhandler", t, raising=False)
- mp.setattr(pytest, "ensuretemp", t.ensuretemp, raising=False)
@pytest.fixture(scope="session")