[PATCH 3 of 3 V2] test-pyflakes: detect undefined name error
Yuya Nishihara
yuya at tcha.org
Fri May 2 05:14:37 CDT 2014
# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1398743641 -32400
# Tue Apr 29 12:54:01 2014 +0900
# Node ID b7b37547eec4246671f7ae28843a6931813b810d
# Parent de513875f008f333f320aca0b236b6e8af54cdbf
test-pyflakes: detect undefined name error
It should be able to catch the following mistakes at 2606e7f227f6:
mercurial/exchange.py:590: undefined name 'UnknownPartError'
mercurial/match.py:346: undefined name 'pat'
mercurial/win32.py:365: undefined name '_ERROR_NO_MORE_FILES'
tests/killdaemons.py:46: undefined name 'check'
diff --git a/tests/filterpyflakes.py b/tests/filterpyflakes.py
--- a/tests/filterpyflakes.py
+++ b/tests/filterpyflakes.py
@@ -32,6 +32,7 @@ for line in sys.stdin:
r"imported but unused",
r"local variable '.*' is assigned to but never used",
r"unable to detect undefined names",
+ r"undefined name '.*'",
]
for msgtype, pat in enumerate(pats):
if re.search(pat, line):
More information about the Mercurial-devel
mailing list