File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed
Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,7 @@ David Mohr
4444David Vierra
4545Diego Russo
4646Dmitry Dygalo
47+ Duncan Betts
4748Edison Gustavo Muenz
4849Edoardo Batini
4950Eduardo Schettino
Original file line number Diff line number Diff line change 113.0.5.dev0
22==========
33
4- *
4+ * Add hint to error message hinting possible missing __init__.py (` #478 `_). Thanks ` @DuncanBetts `_.
55
66* An error message is now displayed if ``--confcutdir `` is not a valid directory, avoiding
77 subtle bugs (`#2078 `_).
2020*
2121
2222.. _@adler-j : https://github.com/adler-j
23+ .. _@DuncanBetts : https://github.com/DuncanBetts
2324.. _@nedbat : https://github.com/nedbat
2425
26+ .. _#478 : https://github.com/pytest-dev/pytest/issues/478
2527.. _#2038 : https://github.com/pytest-dev/pytest/issues/2038
2628.. _#2078 : https://github.com/pytest-dev/pytest/issues/2078
2729.. _#2082 : https://github.com/pytest-dev/pytest/issues/2082
Original file line number Diff line number Diff line change @@ -704,10 +704,9 @@ def _parsearg(self, arg):
704704 path = self .config .invocation_dir .join (relpath , abs = True )
705705 if not path .check ():
706706 if self .config .option .pyargs :
707- msg = "file or package not found: "
707+ raise pytest . UsageError ( "file or package not found: " + arg + " (missing __init__.py?)" )
708708 else :
709- msg = "file not found: "
710- raise pytest .UsageError (msg + arg )
709+ raise pytest .UsageError ("file not found: " + arg )
711710 parts [0 ] = path
712711 return parts
713712
You can’t perform that action at this time.
0 commit comments