tests/test-check-pyflakes.t
author Gregory Szorc <gregory.szorc@gmail.com>
Sat, 13 May 2017 11:31:36 -0700
changeset 32277 80e3002cd29e
parent 30894 5b60464efbde
child 32510 50eaccb8353f
permissions -rw-r--r--
tests: remove special handling for undefined memoryview 'memoryview' was introduced in Python 2.7. 4adc090fa2fb added code to filterpyflakes.py to ignore "undefined name 'memoryview'" pyflakes warnings. Since we no longer support <Python 2.7, we can remove this workaround.

#require test-repo pyflakes hg10

  $ . "$TESTDIR/helpers-testrepo.sh"
  $ cd "`dirname "$TESTDIR"`"

run pyflakes on all tracked files ending in .py or without a file ending
(skipping binary file random-seed)

  $ hg locate 'set:**.py or grep("^#!.*python")' -X hgext/fsmonitor/pywatchman \
  > -X mercurial/pycompat.py -X contrib/python-zstandard \
  > 2>/dev/null \
  > | xargs pyflakes 2>/dev/null | "$TESTDIR/filterpyflakes.py"
  tests/filterpyflakes.py:38: undefined name 'undefinedname'