Skip to content

Commit c780f4e

Browse files
test: Clean up path fixtures
config_path and changelog_path rely on the modified CWD provided by tmp_commitizen_project, so they should use this fixture.
1 parent c0ff3af commit c780f4e

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

Diff for: tests/commands/conftest.py

+1-6
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,5 @@ def config_customize():
4444

4545

4646
@pytest.fixture()
47-
def changelog_path() -> str:
47+
def changelog_path(tmp_commitizen_project) -> str:
4848
return os.path.join(os.getcwd(), "CHANGELOG.md")
49-
50-
51-
@pytest.fixture()
52-
def config_path() -> str:
53-
return os.path.join(os.getcwd(), "pyproject.toml")

Diff for: tests/conftest.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def config():
122122

123123

124124
@pytest.fixture()
125-
def config_path() -> str:
125+
def config_path(tmp_commitizen_project) -> str:
126126
return os.path.join(os.getcwd(), "pyproject.toml")
127127

128128

0 commit comments

Comments
 (0)