Skip to content

Commit

Permalink
test: migrate from tmpdir to tmp_path
Browse files Browse the repository at this point in the history
  • Loading branch information
akaihola committed Oct 28, 2024
1 parent 50bc480 commit 4fc0fa9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/darker/tests/test_command_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -621,11 +621,11 @@ def test_black_options(monkeypatch, tmpdir, git_repo, options, expect):
dict(options=["--preview"], expect_opts=["--preview"]),
expect_opts=[],
)
def test_ruff_options(monkeypatch, tmpdir, git_repo, options, expect_opts):
def test_ruff_options(monkeypatch, tmp_path, git_repo, options, expect_opts):
"""Ruff options from the command line are passed correctly to Ruff."""
monkeypatch.chdir(tmpdir)
(tmpdir / "pyproject.toml").write("[tool.ruff]\n")
(tmpdir / "ruff.cfg").write(
monkeypatch.chdir(tmp_path)
(tmp_path / "pyproject.toml").write_text("[tool.ruff]\n")
(tmp_path / "ruff.cfg").write_text(
dedent(
"""
[tool.ruff]
Expand Down

0 comments on commit 4fc0fa9

Please sign in to comment.