Skip to content

Commit bf83b14

Browse files
david-yz-liuDonny Wong
authored andcommitted
Fixed Python tester to display fully qulaified name when running pytest (#656)
1 parent 7b5cbef commit bf83b14

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ All notable changes to this project will be documented here.
33

44
## [v2.8.3]
55
- Add troubleshooting section talking about Docker Content Trust (DCT) (#653)
6+
- Fixed Python tester to display fully qualified name when running pytest (#656)
67

78
## [v2.8.2]
89
- Changed tasty-discover argument of source directory to a file (#648)

server/autotest_server/testers/py/py_tester.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ def pytest_collectreport(self, report):
196196

197197
def _format_test_name(self, report):
198198
parts = report.nodeid.split("::")
199-
return f"[{parts[0]}] {parts[-1]}" if len(parts) > 1 else f"[{parts[0]}]"
199+
return f"[{parts[0]}] {'.'.join(parts[1:])}" if len(parts) > 1 else f"[{parts[0]}]"
200200

201201

202202
class PyTest(Test):

0 commit comments

Comments
 (0)