Open Bug 1148508 Opened 5 years ago Updated 5 years ago
Do not throw the logcat logs into the trash when running tests ;)
See this try push for example: <https://treeherder.mozilla.org/#/jobs?repo=try&revision=7caff4bcbeb5> I have added dump() statements to my test to printf debug something, and the test framework seems to take my output and throw it into the trash. It would be nice if it stopped doing that!
I think the issue here is that we write a lot to the logcat over the course of a test, the fixed-size logcat is over-written, and when we dump logcat in the test log at the end of the test, it is missing information from earlier. There is also the sometimes forgotten "complete logcat" which captures logcat for the entire duration of the test and should have everything of interest. We usually say we don't want the complete logcat included in the test log because it is too long. We usually say we don't want to discard the partial logcat from the test log because it is sometimes useful (error or crash at the end of the test). I wrote https://gbrownmozilla.wordpress.com/2015/03/27/complete-logcats-for-android-tests-updated-for-2015/ to try to remind everyone where to find the complete logcat.
I wonder if we could just add some code to override where dump() goes to for test runs and send it to a separate log file?
Is it practical to put the dump output always intertwined in the test output?
You need to log in before you can comment on or make changes to this bug.