Skip to content

Commit

Permalink
Merge autoland to mozilla-central. a=merge
Browse files Browse the repository at this point in the history
  • Loading branch information
nerli1 committed Jun 25, 2018
2 parents 499488f + 5c4430a commit c474489
Show file tree
Hide file tree
Showing 96 changed files with 4,789 additions and 1,008 deletions.
14 changes: 7 additions & 7 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ name = "pypi"
[dev-packages]

[packages]
pipenv = "==2018.5.18"
virtualenv = "==15.2.0"
six = "==1.10.0"
attrs = "==18.1.0"
pytest = "==3.2.5"
jsmin = "==2.1.0"
json-e = "==2.5.0"
pipenv = "==2018.5.18"
pytest = "==3.2.5"
python-hglib = "==2.4"

[requires]
python_version = "2.7"
requests = "==2.9.1"
six = "==1.10.0"
virtualenv = "==15.2.0"
voluptuous = "==0.10.5"
28 changes: 24 additions & 4 deletions Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
const BASE_GEO_URL = "http://mochi.test:8888/tests/dom/tests/mochitest/geolocation/network_geolocation.sjs";

/** Test for Bug 1372069 **/
/** Modified for Bug 1441295 **/
SimpleTest.waitForExplicitFinish();
window.onload = () => {
SimpleTest.waitForFocus(() => {
Expand All @@ -30,12 +31,11 @@
function doTest_getCurrentPosition() {
navigator.geolocation.getCurrentPosition(
(position) => {
ok(false, "Success callback is not expected to be called");
ok(true, "Success callback is expected to be called");
doTest_watchPosition();
},
(error) => {
ok(true, "Check for the error callback to be called for fingerprinting resistance");
is(error.code, error.PERMISSION_DENIED, "Check error code for fingerprinting resistance");
ok(false, "Should be able to call success callback, Got error. code = " + error.code);
doTest_watchPosition();
}
);
Expand All @@ -44,13 +44,12 @@
function doTest_watchPosition() {
let wid = navigator.geolocation.watchPosition(
(position) => {
ok(false, "Success callback is not expected to be called");
ok(true, "Success callback is expected to be called");
navigator.geolocation.clearWatch(wid);
SimpleTest.finish();
},
(error) => {
ok(true, "Check for the error callback to be called for fingerprinting resistance");
is(error.code, error.PERMISSION_DENIED, "Check error code for fingerprinting resistance");
ok(false, "Should be able to call success callback, Got error. code = " + error.code);
navigator.geolocation.clearWatch(wid);
SimpleTest.finish();
}
Expand Down
5 changes: 3 additions & 2 deletions build/moz.configure/init.configure
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,11 @@ def virtualenv_python(env_python, build_env, mozconfig, help):
if topobjdir.endswith('/js/src'):
topobjdir = topobjdir[:-7]

virtualenvs_root = os.path.join(topobjdir, '_virtualenvs')
with LineIO(lambda l: log.info(l), 'replace') as out:
manager = VirtualenvManager(
topsrcdir, topobjdir,
os.path.join(topobjdir, '_virtualenvs', 'init'), out,
os.path.join(virtualenvs_root, 'init'), out,
os.path.join(topsrcdir, 'build', 'virtualenv_packages.txt'))

if python:
Expand All @@ -256,7 +257,7 @@ def virtualenv_python(env_python, build_env, mozconfig, help):

python = normsep(manager.python_path)

if python != normsep(sys.executable):
if not normsep(sys.executable).startswith(normsep(virtualenvs_root)):
log.info('Reexecuting in the virtualenv')
if env_python:
del os.environ['PYTHON']
Expand Down
4 changes: 0 additions & 4 deletions devtools/client/locales/en-US/layout.properties
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,3 @@ layout.overlayMultipleGrids=Overlay Multiple Grids
# LOCALIZATION NOTE (layout.overlayGrid): Alternate header for the list of grid container
# elements if only one item can be selected.
layout.overlayGrid=Overlay Grid

# LOCALIZATION NOTE (layout.rowColumnPositions): The row and column position of a grid
# cell shown in the grid cell infobar when hovering over the CSS grid outline.
layout.rowColumnPositions=Row %S / Column %S
6 changes: 0 additions & 6 deletions devtools/client/locales/en-US/netmonitor.properties
Original file line number Diff line number Diff line change
Expand Up @@ -466,12 +466,6 @@ certmgr.certdetail.sha1fingerprint=SHA1 Fingerprint:
# This string is used as a label in the security tab.
certmgr.certificateTransparency.label=Transparency:

# LOCALIZATION NOTE (certmgr.certificateTransparency.status.none):
# This string is used to indicate that there are no signed certificate
# timestamps available. This is a property for the 'Transparency'
# field in the security tab.
certmgr.certificateTransparency.status.none=No SCT records

# LOCALIZATION NOTE (certmgr.certificateTransparency.status.ok):
# This string is used to indicate that there are valid signed certificate
# timestamps. This is a property for the 'Transparency'
Expand Down
46 changes: 45 additions & 1 deletion devtools/client/netmonitor/src/components/SecurityPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,24 @@ const DISABLED_LABEL = L10N.getStr("netmonitor.security.disabled");
const CONNECTION_LABEL = L10N.getStr("netmonitor.security.connection");
const PROTOCOL_VERSION_LABEL = L10N.getStr("netmonitor.security.protocolVersion");
const KEA_GROUP_LABEL = L10N.getStr("netmonitor.security.keaGroup");
const KEA_GROUP_NONE = L10N.getStr("netmonitor.security.keaGroup.none");
const KEA_GROUP_CUSTOM = L10N.getStr("netmonitor.security.keaGroup.custom");
const KEA_GROUP_UNKNOWN = L10N.getStr("netmonitor.security.keaGroup.unknown");
const SIGNATURE_SCHEME_LABEL = L10N.getStr("netmonitor.security.signatureScheme");
const SIGNATURE_SCHEME_NONE = L10N.getStr("netmonitor.security.signatureScheme.none");
const SIGNATURE_SCHEME_UNKNOWN =
L10N.getStr("netmonitor.security.signatureScheme.unknown");
const HSTS_LABEL = L10N.getStr("netmonitor.security.hsts");
const HPKP_LABEL = L10N.getStr("netmonitor.security.hpkp");
const CERTIFICATE_LABEL = L10N.getStr("netmonitor.security.certificate");
const CERTIFICATE_TRANSPARENCY_LABEL =
L10N.getStr("certmgr.certificateTransparency.label");
L10N.getStr("certmgr.certificateTransparency.label");
const CERTIFICATE_TRANSPARENCY_POLICY_COMPLIANT =
L10N.getStr("certmgr.certificateTransparency.status.ok");
const CERTIFICATE_TRANSPARENCY_POLICY_NOT_ENOUGH_SCTS =
L10N.getStr("certmgr.certificateTransparency.status.notEnoughSCTS");
const CERTIFICATE_TRANSPARENCY_POLICY_NOT_DIVERSE_SCTS =
L10N.getStr("certmgr.certificateTransparency.status.notDiverseSCTS");
const SUBJECT_INFO_LABEL = L10N.getStr("certmgr.subjectinfo.label");
const CERT_DETAIL_COMMON_NAME_LABEL = L10N.getStr("certmgr.certdetail.cn");
const CERT_DETAIL_ORG_LABEL = L10N.getStr("certmgr.certdetail.o");
Expand Down Expand Up @@ -122,6 +134,38 @@ class SecurityPanel extends Component {
const HOST_HEADER_LABEL = L10N.getFormatStr("netmonitor.security.hostHeader",
getUrlHost(url));

// Localize special values for key exchange group name.
if (securityInfo.keaGroupName == "none") {
securityInfo.keaGroupName = KEA_GROUP_NONE;
}
if (securityInfo.keaGroupName == "custom") {
securityInfo.keaGroupName = KEA_GROUP_CUSTOM;
}
if (securityInfo.keaGroupName == "unknown group") {
securityInfo.keaGroupName = KEA_GROUP_UNKNOWN;
}

// Localize special values for certificate signature scheme.
if (securityInfo.signatureSchemeName == "none") {
securityInfo.signatureSchemeName = SIGNATURE_SCHEME_NONE;
}
if (securityInfo.signatureSchemeName == "unknown signature") {
securityInfo.signatureSchemeName = SIGNATURE_SCHEME_UNKNOWN;
}

// Localize special values for certificate transparency status.
if (securityInfo.certificateTransparency == 5) {
securityInfo.certificateTransparency = CERTIFICATE_TRANSPARENCY_POLICY_COMPLIANT;
}
if (securityInfo.certificateTransparency == 6) {
securityInfo.certificateTransparency =
CERTIFICATE_TRANSPARENCY_POLICY_NOT_ENOUGH_SCTS;
}
if (securityInfo.certificateTransparency == 7) {
securityInfo.certificateTransparency =
CERTIFICATE_TRANSPARENCY_POLICY_NOT_DIVERSE_SCTS;
}

object = {
[CONNECTION_LABEL]: {
[PROTOCOL_VERSION_LABEL]:
Expand Down
2 changes: 1 addition & 1 deletion devtools/client/netmonitor/src/components/TabboxPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ TabboxPanel.propTypes = {
request: PropTypes.object,
selectTab: PropTypes.func.isRequired,
sourceMapService: PropTypes.object,
hideToggleButton: PropTypes.boolean,
hideToggleButton: PropTypes.bool,
};

module.exports = TabboxPanel;
13 changes: 11 additions & 2 deletions devtools/client/performance/test/head.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,17 @@

const { require, loader } = ChromeUtils.import("resource://devtools/shared/Loader.jsm", {});

Services.scriptloader.loadSubScript(
"chrome://mochitests/content/browser/devtools/client/shared/test/telemetry-test-helpers.js", this);
try {
Services.scriptloader.loadSubScript(
"chrome://mochitests/content/browser/devtools/client/shared/test/telemetry-test-helpers.js", this);
} catch (e) {
ok(false,
"MISSING DEPENDENCY ON telemetry-test-helpers.js\n" +
"Please add the following line in browser.ini:\n" +
" !/devtools/client/shared/test/telemetry-test-helpers.js\n"
);
throw e;
}

/* exported loader, either, click, dblclick, mousedown, rightMousedown, key */
// All tests are asynchronous.
Expand Down
1 change: 1 addition & 0 deletions devtools/client/responsive.html/browser/swap.js
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ function swapToInnerBrowser({ tab, containerURL, getInnerBrowser }) {

// Show the browser content again now that the move is done.
tab.linkedBrowser.style.visibility = "";
debug("Exit swap start");
},

stop() {
Expand Down
4 changes: 4 additions & 0 deletions devtools/client/responsive.html/browser/tunnel.js
Original file line number Diff line number Diff line change
Expand Up @@ -374,9 +374,13 @@ MessageManagerTunnel.prototype = {
"Forms:SelectDropDownItem",
// Messages sent from SessionStore.jsm
"SessionStore:flush",
"SessionStore:restoreHistory",
"SessionStore:restoreTabContent",
],

INNER_TO_OUTER_MESSAGES: [
// Messages sent to browser.js
"Browser:LoadURI",
// Messages sent to RemoteWebProgress.jsm
"Content:LoadURIResult",
"Content:LocationChange",
Expand Down
2 changes: 2 additions & 0 deletions devtools/client/responsive.html/test/browser/browser.ini
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ support-files =
!/devtools/client/shared/test/test-actor-registry.js

[browser_cmd_click.js]
[browser_container_tab.js]
[browser_contextual_identity.js]
[browser_device_change.js]
[browser_device_custom_remove.js]
Expand All @@ -44,6 +45,7 @@ skip-if = true # Bug 1413765
[browser_permission_doorhanger.js]
tags = devtools geolocation
skip-if = true # Bug 1413765
[browser_preloaded_newtab.js]
[browser_screenshot_button.js]
[browser_tab_close.js]
[browser_tab_remoteness_change.js]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/* Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/ */

"use strict";

// Verify RDM opens for a container tab.

const TEST_URL = "http://example.com/";

add_task(async function() {
// Open a tab with about:newtab in a container.
const tab = await addTab(BROWSER_NEW_TAB_URL, {
userContextId: 2,
});
is(tab.userContextId, 2, "Tab's container ID is correct");
const browser = tab.linkedBrowser;

// Open RDM and try to navigate
const { ui } = await openRDM(tab);
const loaded = waitForFrameLoad(ui, TEST_URL);
await load(browser, TEST_URL);
await loaded;
ok(true, "Test URL navigated successfully");

await closeRDM(tab);
await removeTab(tab);
});
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ const TEST_URL = TEST_URI_ROOT + "contextual_identity.html";
// Opens `uri' in a new tab with the provided userContextId.
// Returns the newly opened tab and browser.
async function addTabInUserContext(uri, userContextId) {
const tab = BrowserTestUtils.addTab(gBrowser, uri, { userContextId });
gBrowser.selectedTab = tab;
const browser = gBrowser.getBrowserForTab(tab);
await BrowserTestUtils.browserLoaded(browser);
const tab = await addTab(uri, { userContextId });
const browser = tab.linkedBrowser;
return { tab, browser };
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/* Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/ */

"use strict";

// Verify RDM opens for a preloaded about:newtab browser.

const TEST_URL = "http://example.com/";

add_task(async function() {
// Open a tab with about:newtab.
// Don't wait for load because the page is preloaded.
const tab = await addTab(BROWSER_NEW_TAB_URL, {
waitForLoad: false,
});
const browser = tab.linkedBrowser;
is(browser.getAttribute("preloadedState"), "consumed",
"Got a preloaded browser for newtab");

// Open RDM and try to navigate
const { ui } = await openRDM(tab);
const loaded = waitForFrameLoad(ui, TEST_URL);
await load(browser, TEST_URL);
await loaded;
ok(true, "Test URL navigated successfully");

await closeRDM(tab);
await removeTab(tab);
});
4 changes: 2 additions & 2 deletions devtools/client/responsive.html/test/browser/head.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ function waitForFrameLoad(ui, targetURL) {

function waitForViewportResizeTo(ui, width, height) {
return new Promise(async function(resolve) {
const isSizeMatching = (data) => data.width == width && data.height == height;
const isSizeMatching = data => data.width == width && data.height == height;

// If the viewport has already the expected size, we resolve the promise immediately.
const size = await getContentSize(ui);
Expand Down Expand Up @@ -158,7 +158,7 @@ function waitForViewportResizeTo(ui, width, height) {

const onBrowserLoadEnd = async function() {
const data = await getContentSize(ui);
onResize(undefined, data);
onResize(data);
};

info(`Waiting for content-resize to ${width} x ${height}`);
Expand Down
Loading

0 comments on commit c474489

Please sign in to comment.