summaryrefslogtreecommitdiff
path: root/tests/functional/l/logging_not_lazy_with_logger.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/functional/l/logging_not_lazy_with_logger.py')
-rw-r--r--tests/functional/l/logging_not_lazy_with_logger.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/functional/l/logging_not_lazy_with_logger.py b/tests/functional/l/logging_not_lazy_with_logger.py
new file mode 100644
index 000000000..ef2221f23
--- /dev/null
+++ b/tests/functional/l/logging_not_lazy_with_logger.py
@@ -0,0 +1,13 @@
+"""Logging warnings using a logger class."""
+from __future__ import absolute_import
+import logging
+
+__revision__ = ''
+
+LOG = logging.getLogger("domain")
+LOG.debug("%s" % "junk") # [logging-not-lazy]
+LOG.log(logging.DEBUG, "%s" % "junk") # [logging-not-lazy]
+LOG2 = LOG.debug
+LOG2("%s" % "junk") # [logging-not-lazy]
+
+logging.getLogger("domain").debug("%s" % "junk") # [logging-not-lazy]