We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 698e979 commit ca37cb5Copy full SHA for ca37cb5
launch_testing/launch_testing/pytest/hooks.py
@@ -157,8 +157,10 @@ def makeitem(self, *args, **kwargs):
157
return LaunchTestItem.from_parent(*args, **kwargs)
158
159
def collect(self):
160
- if _pytest_version_ge(7):
161
- # self.path exists since 7
+ if _pytest_version_ge(8, 1, 0):
+ from _pytest.pathlib import import_path
162
+ module = import_path(self.path, root=None, consider_namespace_packages=False)
163
+ elif _pytest_version_ge(7, 0, 0):
164
from _pytest.pathlib import import_path
165
module = import_path(self.path, root=None)
166
else:
@@ -173,7 +175,10 @@ def collect(self):
173
175
174
176
def find_launch_test_entrypoint(path):
177
try:
178
179
180
+ module = import_path(path, root=None, consider_namespace_packages=False)
181
182
183
module = import_path(path, root=None)
184
0 commit comments