diff options
author | Ashley Whetter <ashley@awhetter.co.uk> | 2019-06-14 22:28:42 -0700 |
---|---|---|
committer | Claudiu Popa <pcmanticore@gmail.com> | 2019-06-20 10:02:14 +0200 |
commit | 33b8185a455c1686d038258697bb93005f2441c2 (patch) | |
tree | 4a50ccac775c009436e45803129e428ed694065f /tests/input/func_e12xx.py | |
parent | 7081d91f30728653000bdfc59ea85a3395f96418 (diff) | |
download | pylint-git-33b8185a455c1686d038258697bb93005f2441c2.tar.gz |
Stopped installing tests with package
Diffstat (limited to 'tests/input/func_e12xx.py')
-rw-r--r-- | tests/input/func_e12xx.py | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/input/func_e12xx.py b/tests/input/func_e12xx.py new file mode 100644 index 000000000..74984d998 --- /dev/null +++ b/tests/input/func_e12xx.py @@ -0,0 +1,28 @@ +# pylint: disable=E1101, no-absolute-import +"""Test checking of log format strings +""" + +import logging + +__revision__ = '' + + +def pprint(): + """Test string format in logging statements. + """ + # These should all emit lint errors: + logging.info(0, '') # 1205 + logging.info('', '') # 1205 + logging.info('%s%', '') # 1201 + logging.info('%s%s', '') # 1206 + logging.info('%s%y', '', '') # 1200 + logging.info('%s%s', '', '', '') # 1205 + + # These should be okay: + logging.info(1) + logging.info(True) + logging.info('') + logging.info('%s%') + logging.info('%s', '') + logging.info('%s%%', '') + logging.info('%s%s', '', '') |