Closed Bug 1161198 Opened 5 years ago Closed 5 years ago

sut_logcat.TestLogCat.test_getLogcat | AssertionError: Lists differ: ['07-17 00:51:10.377 I/SUTAgen... != ['07-17 00:51:10.377 I/SUTAgen...

Categories

(Testing :: Mozbase, defect)

defect
Not set

Tracking

(firefox40 fixed)

RESOLVED FIXED
mozilla40
Tracking Status
firefox40 --- fixed

People

(Reporter: gbrown, Assigned: gbrown)

References

Details

Attachments

(1 file, 1 obsolete file)

My patch in bug 1160351	caused a regression in the mozdevice test for getLogcat:

http://ftp.mozilla.org/pub/mozilla.org/firefox/tinderbox-builds/mozilla-inbound-linux/1430763346/mozilla-inbound-linux-bm94-build1-build732.txt.gz

12:07:35     INFO - TEST-START | sut_logcat.TestLogCat.test_getLogcat
12:07:35  WARNING - TEST-UNEXPECTED-FAIL | sut_logcat.TestLogCat.test_getLogcat | AssertionError: Lists differ: ['07-17 00:51:10.377 I/SUTAgen... != ['07-17 00:51:10.377 I/SUTAgen...
12:07:35     INFO - First differing element 1:
12:07:35     INFO - 07-17 00:51:10.457 D/dalvikvm( 2933): GC_CONCURRENT freed 351K, 17% free 2523K/3008K, paused 5ms+2ms, total 38ms
12:07:35     INFO - Second list contains 14 additional elements.
12:07:35     INFO - First extra element 15:
12:07:35     INFO - Diff is 1715 characters long. Set self.maxDiff to None to see it.
12:07:35     INFO - Traceback (most recent call last):
12:07:35     INFO -   File "/builds/slave/m-in-lx-0000000000000000000000/build/src/testing/mozbase/mozdevice/tests/sut_logcat.py", line 39, in test_getLogcat
12:07:35     INFO -     self.assertEqual(logcat_output[:-17].split('\r'), d.getLogcat())
12:07:35     INFO - TEST-INFO took 46ms

(Thankfully/unexpectedly, the build remains green on treeherder.)
Comment on attachment 8601079 [details] [diff] [review]
update mozdevice test for getLogcat

Review of attachment 8601079 [details] [diff] [review]:
-----------------------------------------------------------------

::: testing/mozbase/mozdevice/tests/sut_logcat.py
@@ +11,4 @@
>  
>      def test_getLogcat(self):
>  
>          logcat_output = ("07-17 00:51:10.377 I/SUTAgentAndroid( 2933): onCreate\n\r"

We don't have to worry about the different order of \n\r in this versus what we expected \r\n ?
I suppose it makes more sense to use the line endings we find in real life.
Attachment #8601079 - Attachment is obsolete: true
Attachment #8601079 - Flags: review?(bob)
Attachment #8601117 - Flags: review?(bob)
Attachment #8601117 - Flags: review?(bob) → review+
https://hg.mozilla.org/mozilla-central/rev/35b1653bdf2b
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in before you can comment on or make changes to this bug.