Skip to content

Commit

Permalink
test_traverse_project: Fix incorrect .project member for a test vector
Browse files Browse the repository at this point in the history
One of the test vector passed a nonsense TraverseProjectVector.project
member that did not point to an actual project under
tests/sample_projects. Fix that, and add an assert to the test logic
below to ensure this does not happen again.
  • Loading branch information
jherland committed May 30, 2023
1 parent 91d5dcd commit 11ebb34
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/test_traverse_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ class TraverseProjectVector:
),
TraverseProjectVector(
"given_deps_as_non_deps_file__raises_exception",
"README.md",
"blog_post_example",
code=set(),
deps={"README.md"},
expect_raised=UnparseablePathException,
Expand Down Expand Up @@ -315,6 +315,7 @@ class TraverseProjectVector:
)
def test_find_sources(vector: TraverseProjectVector):
project_dir = SAMPLE_PROJECTS_DIR / vector.project
assert project_dir.is_dir()
settings = Settings(
code={
path if path == "<stdin>" else project_dir / path for path in vector.code
Expand Down

0 comments on commit 11ebb34

Please sign in to comment.