Development of an internal social media platform with personalised dashboards for students
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

func_bug113231.py 559B

123456789101112131415161718192021222324
  1. # pylint: disable=E1101
  2. # pylint: disable=C0103
  3. # pylint: disable=R0903
  4. """test bugfix for #113231 in logging checker
  5. """
  6. from __future__ import absolute_import
  7. # Muck up the names in an effort to confuse...
  8. import logging as renamed_logging
  9. __revision__ = ''
  10. class Logger(object):
  11. """Fake logger"""
  12. pass
  13. logger = renamed_logging.getLogger(__name__)
  14. fake_logger = Logger()
  15. # Statements that should be flagged:
  16. renamed_logging.warning('%s, %s' % (4, 5))
  17. logger.warning('%s' % 5)
  18. # Statements that should not be flagged:
  19. fake_logger.warn('%s' % 5)