launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #09238
[Merge] lp:~gz/launchpad/py27_test_scriptmonitor_logging_1017981 into lp:launchpad
Martin Packman has proposed merging lp:~gz/launchpad/py27_test_scriptmonitor_logging_1017981 into lp:launchpad.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
Related bugs:
Bug #1017981 in Launchpad itself: "Test failures in lp.scripts.tests.test_scriptmonitor on Python 2.7"
https://bugs.launchpad.net/launchpad/+bug/1017981
For more details, see:
https://code.launchpad.net/~gz/launchpad/py27_test_scriptmonitor_logging_1017981/+merge/112160
Fix three test failures on python 2.7 from stricter checking of arguments in standard library logging module.
These three tests don't actually care about log output, but create a logger that outputs to /dev/null as well as stderr. By using None instead, the logging to file at least can be skipped. Even less setup could be done by passing in a locally created log object rather than reusing the generic setup.
--
https://code.launchpad.net/~gz/launchpad/py27_test_scriptmonitor_logging_1017981/+merge/112160
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~gz/launchpad/py27_test_scriptmonitor_logging_1017981 into lp:launchpad.
=== modified file 'lib/lp/scripts/tests/test_scriptmonitor.py'
--- lib/lp/scripts/tests/test_scriptmonitor.py 2011-12-30 06:14:56 +0000
+++ lib/lp/scripts/tests/test_scriptmonitor.py 2012-06-26 16:15:41 +0000
@@ -22,7 +22,7 @@
# sys.args. We don't care about the log messages, so just throw them
# away.
class FakeOptions:
- log_file = '/dev/null'
+ log_file = None
loglevel = 1000
verbose = False
self.con = connect()
Follow ups