The default bug view has changed. See this FAQ.

xpcshell test netwerk/test/unit/test_bug650955.js fails on Android

RESOLVED FIXED in mozilla9

Status

()

Core
Networking: Cache
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: gbrown, Assigned: gbrown)

Tracking

Trunk
mozilla9
x86
Android
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [mobile-testing][xpcshell])

Attachments

(3 attachments, 1 obsolete attachment)

(Assignee)

Description

6 years ago
With patches for bug 668349 and 668351, xpcshell tests can be run on an Android device, and the majority of tests pass. 

However, netwerk/test/unit/test_bug650955.js consistently fails when run on Android.

(I thought this might be related to intermittent failures of this test on Mac, and tried applying the patch from Bug 667593, but that did not help -- the test failed with identical error messages).
(Assignee)

Comment 1

6 years ago
Created attachment 551632 [details]
log showing xpcshell output for test_bug650955.js on Android
(Assignee)

Updated

6 years ago
Whiteboard: [mobile-testing][xpcshell]
(Assignee)

Comment 2

6 years ago
Created attachment 553275 [details]
necko log of failed test run on Android
(Assignee)

Comment 3

6 years ago
The memory cache tests pass, but the disk cache tests fail. The problem is that the preference browser.cache.disk.capacity has a default of 0 in Fennec, so the disk cache is still effectively disabled, even after browser.cache.disk.enable is set to true.
Assignee: nobody → gbrown
(Assignee)

Comment 4

6 years ago
Created attachment 555125 [details] [diff] [review]
patch for review

test_bug650955.js passes reliably with this patch. If enabling the disk cache and disk cache capacity is 0, capacity is set to 1024 (an arbitrary, small cache). To guard against a similar issue arising with the memory cache, a similar check is made for the memory cache capacity, when enabling the memory cache.
Attachment #555125 - Flags: review?(bjarne)
(Assignee)

Comment 5

6 years ago
Created attachment 555265 [details] [diff] [review]
patch for review

I noticed a problem with the previous patch: If either of the capacity prefs does not exist, the test fails. Now updated to allow for non-existent prefs.
Attachment #555125 - Attachment is obsolete: true
Attachment #555125 - Flags: review?(bjarne)
Attachment #555265 - Flags: review?(bjarne)

Comment 6

6 years ago
Comment on attachment 555265 [details] [diff] [review]
patch for review

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

Nice
Attachment #555265 - Flags: review?(bjarne) → review+
(Assignee)

Updated

6 years ago
Keywords: checkin-needed
Comment on attachment 555265 [details] [diff] [review]
patch for review

I fixed end-of-line whitespace...
>+        if (memDevice) {
>+            try {
>+                cap = prefService.getIntPref("browser.cache.memory.capacity");
>+            } 
...here -------^

>+        if (diskDevice) {
>+            try {
>+                cap = prefService.getIntPref("browser.cache.disk.capacity");
>+            } 
...and here ---^

and pushed to mozilla-inbound:
http://hg.mozilla.org/integration/mozilla-inbound/rev/bc6b53c4e931
Keywords: checkin-needed
Whiteboard: [mobile-testing][xpcshell] → [mobile-testing][xpcshell][inbound]
Target Milestone: --- → mozilla9
Version: unspecified → Trunk
http://hg.mozilla.org/mozilla-central/rev/bc6b53c4e931
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Whiteboard: [mobile-testing][xpcshell][inbound] → [mobile-testing][xpcshell]
You need to log in before you can comment on or make changes to this bug.