Skip to content

Commit

Permalink
Fix agent
Browse files Browse the repository at this point in the history
  • Loading branch information
HardNorth committed Nov 22, 2024
1 parent 3500c39 commit 4f33203
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pytest_reportportal/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

from _pytest.doctest import DoctestItem
from aenum import auto, Enum, unique
from py.path import local
from pytest import Class, Function, Module, Package, Item, Session, PytestWarning
from reportportal_client.aio import Task
from reportportal_client.core.rp_issues import Issue, ExternalIssue
Expand Down Expand Up @@ -209,7 +210,7 @@ def start_launch(self) -> Optional[str]:
LOGGER.debug('ReportPortal - Launch started: id=%s', self._launch_id)
return self._launch_id

def _get_item_dirs(self, item: Item) -> List[str]:
def _get_item_dirs(self, item: Item) -> List[local]:
"""
Get directory of item.
Expand All @@ -219,7 +220,7 @@ def _get_item_dirs(self, item: Item) -> List[str]:
root_path = item.session.config.rootdir.strpath
dir_path = item.fspath.new(basename="")
rel_dir = dir_path.new(dirname=dir_path.relto(root_path), basename="", drive="")
return [str(d) for d in rel_dir.parts(reverse=False) if d.basename]
return [d for d in rel_dir.parts(reverse=False) if d.basename]

def _get_tree_path(self, item: Item) -> List[Item]:
"""Get item of parents.
Expand Down

0 comments on commit 4f33203

Please sign in to comment.