We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 03e761d commit eff32b1Copy full SHA for eff32b1
1 file changed
Lib/doctest.py
@@ -2665,7 +2665,7 @@ def _test():
2665
testfiles = [arg for arg in sys.argv[1:] if arg and arg[0] != '-']
2666
if not testfiles:
2667
name = os.path.basename(sys.argv[0])
2668
- if '__loader__' in globals() and name.endswith('.py'): # python -m
+ if '__loader__' in globals(): # python -m
2669
name, _ = os.path.splitext(name)
2670
print("usage: {0} [-v] file ...".format(name))
2671
return 2
0 commit comments