Skip to content

Commit 5f2af6f

Browse files
committed
Fix test address in "basic_test_info.txt" for subfolder tests
1 parent 0154f25 commit 5f2af6f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

seleniumbase/core/log_helper.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,9 @@ def get_test_id(test):
316316

317317

318318
def get_test_name(test):
319-
if test.is_pytest:
319+
if "PYTEST_CURRENT_TEST" in os.environ:
320+
test_name = os.environ["PYTEST_CURRENT_TEST"].split(" ")[0]
321+
elif test.is_pytest:
320322
test_name = "%s.py::%s::%s" % (
321323
test.__class__.__module__.split(".")[-1],
322324
test.__class__.__name__,

0 commit comments

Comments
 (0)