Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
michael@0 | 1 | from b2g_update_test import B2GUpdateTestCase, OTA, FOTA |
michael@0 | 2 | import os |
michael@0 | 3 | |
michael@0 | 4 | this_dir = os.path.abspath(os.path.dirname(__file__)) |
michael@0 | 5 | update_test_dir = os.path.dirname(this_dir) |
michael@0 | 6 | |
michael@0 | 7 | class UpdateTestStatus(B2GUpdateTestCase): |
michael@0 | 8 | B2G_UPDATES = "/data/local/b2g-updates" |
michael@0 | 9 | |
michael@0 | 10 | def setUp(self): |
michael@0 | 11 | # Stage a phony update to get the http server up and running |
michael@0 | 12 | mar_path = os.path.join(update_test_dir, "unit", "data", "simple.mar") |
michael@0 | 13 | self.stage_update(complete_mar=mar_path) |
michael@0 | 14 | |
michael@0 | 15 | bad_xml = os.path.join(this_dir, "data", "bad.xml") |
michael@0 | 16 | err_cgi = os.path.join(this_dir, "data", "err.cgi") |
michael@0 | 17 | self.runner.adb.push(bad_xml, self.B2G_UPDATES + "/bad.xml") |
michael@0 | 18 | self.runner.adb.shell("mkdir " + self.B2G_UPDATES + "/cgi-bin") |
michael@0 | 19 | self.runner.adb.push(err_cgi, self.B2G_UPDATES + "/cgi-bin/err.cgi") |
michael@0 | 20 | self.runner.adb.shell("chmod 755 " + self.B2G_UPDATES + "/cgi-bin/err.cgi") |
michael@0 | 21 | |
michael@0 | 22 | B2GUpdateTestCase.setUp(self) |
michael@0 | 23 | |
michael@0 | 24 | def test_status(self): |
michael@0 | 25 | self.marionette.set_script_timeout(30 * 1000) |
michael@0 | 26 | status_js = os.path.join(os.path.dirname(__file__), |
michael@0 | 27 | "update_test_status.js") |
michael@0 | 28 | self.execute_update_test(status_js) |
michael@0 | 29 |