-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: split unit/functional tests and reduce project bootstrap boiler…
…plate (#350) * test: split unit and functional tests * test: reduce project bootstrap boilerplate
- Loading branch information
1 parent
d7ee7b2
commit 8b956e4
Showing
39 changed files
with
225 additions
and
238 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
from __future__ import annotations | ||
|
||
from typing import TYPE_CHECKING | ||
|
||
from click.testing import CliRunner | ||
|
||
from deptry.cli import deptry | ||
from tests.utils import get_issues_report, run_within_dir | ||
|
||
if TYPE_CHECKING: | ||
from tests.functional.types import ToolSpecificProjectBuilder | ||
|
||
|
||
def test_cli_with_pdm(pdm_project_builder: ToolSpecificProjectBuilder) -> None: | ||
with run_within_dir(pdm_project_builder("project_with_pdm")): | ||
result = CliRunner().invoke(deptry, ". -o report.json") | ||
|
||
assert result.exit_code == 1 | ||
assert get_issues_report() == { | ||
"misplaced_dev": ["black"], | ||
"missing": ["white"], | ||
"obsolete": ["isort", "requests"], | ||
"transitive": [], | ||
} |
Oops, something went wrong.