Bug 907770 - Part 2: Test changes for https support on b2g/android. r=jmaher

This commit is contained in:
Martin Thomson 2014-03-14 11:25:48 -07:00
parent 1239022073
commit 9ade181aa5
2 changed files with 3 additions and 19 deletions

View File

@ -219,11 +219,9 @@ support-files =
wholeTexty-helper.xml
[test_CrossSiteXHR.html]
skip-if = toolkit == 'android'
[test_CrossSiteXHR_cache.html]
skip-if = toolkit == 'android'
[test_CrossSiteXHR_origin.html]
skip-if = buildapp == 'b2g' || toolkit == 'android' || e10s # b2g(https not working, bug 907770) b2g-debug(https not working, bug 907770) b2g-desktop(https not working, bug 907770)
skip-if = buildapp == 'b2g' || e10s # last test fails to trigger onload on e10s/b2g
[test_DOMException.html]
[test_EventSource_redirects.html]
[test_NodeIterator_basics_filters.xhtml]

View File

@ -43,17 +43,11 @@ function getUA(host) {
function testUA(options, callback) {
var [domain, override, test_hosts, skip, expected] =
[options.domain, options.override, options.test_hosts, options.skip, options.expected];
var [domain, override, test_hosts, expected] =
[options.domain, options.override, options.test_hosts, options.expected];
info('Overriding ' + domain + ' with ' + override);
if (skip) {
todo(false, 'Skipping');
callback();
return;
}
function is_subdomain(host) {
var [test_domain] = host.slice(host.lastIndexOf('/') + 1).split(':', 1);
return test_domain === domain || test_domain.endsWith('.' + domain);
@ -104,12 +98,6 @@ function testUA(options, callback) {
});
}
// mochitests on Android appear to have trouble with https
// but when it eventually works, we should re-enable the test
var skipHttps = /android/i.test(DEFAULT_UA);
if (skipHttps) {
SimpleTest.doesThrow(function () getUA('https://example.com'), 'Re-enable https test');
}
var step = 0; // for logging
var tests = [
@ -150,7 +138,6 @@ var tests = [
// should work with https
{
skip: skipHttps,
domain: 'example.com',
override: UA_WHOLE_OVERRIDE,
test_hosts: ['https://example.com',
@ -243,4 +230,3 @@ testOverrides(function ()
</pre>
</body>
</html>