LaunchpadScript constructor breaks logging for subsequent tests
Bug #694152 reported by
Jonathan Lange
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Triaged
|
Low
|
Unassigned |
Bug Description
LaunchpadScript changes the global root logger to print any logged messages to stderr. While this is great for actual scripts, it means that whenever we invoke LaunchpadScript in a test run, any subsequent tests that log to *any* logger that is set to propagate (the default) will print to stderr.
This is ugly and makes debugging harder by adding extraneous noise.
An example of this is gettext_
Changed in launchpad: | |
status: | New → Triaged |
importance: | Undecided → High |
tags: | added: build-infrastructure |
To post a comment you must log in.
Tests should probably use the FakeLogger fixture from fixtures if they want logging message anyhow; tests that construct a LaunchpadScript should isolate it and restore afterward.