Skip to content

Commit d333a5b

Browse files
authored
Merge pull request #34 from azure-ai-foundry/python-tools-estraight
updated conftest
2 parents ddb6ed7 + f3eea30 commit d333a5b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

conftest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Purpose
44
# -------
55
# Treat every Python sample under doc-samples/agents/python/**
6-
# as a Pytest test item. The script passes if it runs without
6+
# as a Pytest test item. The script "passes" if it runs without
77
# raising an exception (exit code 0).
88
#
99
# How it works
@@ -49,7 +49,7 @@ def pytest_collect_file(parent, path):
4949
`path` is a py.path.local object; convert to Path for easier checks.
5050
"""
5151
if path.ext == ".py" and _is_under_sample_root(pathlib.Path(path)):
52-
return SampleItem.from_parent(parent, fspath=path)
52+
return SampleItem.from_parent(parent, name=path.basename, fspath=path)
5353

5454

5555
class SampleItem(pytest.Item):

0 commit comments

Comments
 (0)