##// END OF EJS Templates
pycompat: custom implementation of urllib.parse.quote()...
pycompat: custom implementation of urllib.parse.quote() urllib.parse.quote() accepts either str or bytes and returns str. There exists a urllib.parse.quote_from_bytes() which only accepts bytes. We should probably use that to retain strong typing and avoid surprises. In addition, since nearly all strings in Mercurial are bytes, we probably don't want quote() returning unicode. So, this patch implements a custom quote() that only accepts bytes and returns bytes. The quoted URL should only contain URL safe characters which is a strict subset of ASCII. So `.encode('ascii', 'strict')` should be safe.

File last commit:

r30894:5b60464e default
r31400:fb1f7033 default
Show More
test-check-pyflakes.t
14 lines | 497 B | text/troff | Tads3Lexer
/ tests / test-check-pyflakes.t
timeless
tests: mark test-check-pyflakes.t as requiring hg1.0+...
r29138 #require test-repo pyflakes hg10
Matt Mackall
tests: add repository check for pyflakes test...
r21208
timeless
tests: silence test-repo obsolete warning...
r29219 $ . "$TESTDIR/helpers-testrepo.sh"
Thomas Arendsen Hein
tests: make tests work if directory contains special characters...
r16350 $ cd "`dirname "$TESTDIR"`"
Simon Heimberg
tests: run pyflakes on files from manifest which could be python files...
r19377
run pyflakes on all tracked files ending in .py or without a file ending
(skipping binary file random-seed)
Matt Mackall
tests: add repository check for pyflakes test...
r21208
Zack Hricz
tests: exclude bundled pywatchman from test-check-pyflakes...
r30655 $ hg locate 'set:**.py or grep("^#!.*python")' -X hgext/fsmonitor/pywatchman \
Augie Fackler
tests: exclude python-zstandard from pyflakes analysis
r30894 > -X mercurial/pycompat.py -X contrib/python-zstandard \
Pulkit Goyal
pycompat: make pycompat demandimport friendly...
r29584 > 2>/dev/null \
Simon Heimberg
tests: run pyflakes on files from manifest which could be python files...
r19377 > | xargs pyflakes 2>/dev/null | "$TESTDIR/filterpyflakes.py"
Augie Fackler
filterpyflakes: dramatically simplify the entire thing by blacklisting...
r30421 tests/filterpyflakes.py:39: undefined name 'undefinedname'
Matt Mackall
tests: fix pyflakes test whitespace breakage
r22053