Bug 1889669 - add mozinfo to reftest sandbox. r=ahal

Differential Revision: https://phabricator.services.mozilla.com/D206658
This commit is contained in:
Joel Maher 2024-04-11 16:29:15 +00:00
parent f17de8a722
commit c61efed4a4
7 changed files with 19 additions and 8 deletions

View file

@ -727,7 +727,7 @@ skip-if = ["os == 'android'"] # android(bug 1232305)
["test_mediarecorder_principals.html"] ["test_mediarecorder_principals.html"]
skip-if = [ skip-if = [
"os == 'win' && os_version == '10.0'", # Bug 1453375 "os == 'win' && os_version == '10.2009'", # Bug 1453375
"os == 'android'", # Bug 1694645 "os == 'android'", # Bug 1694645
] ]

View file

@ -51,7 +51,7 @@ skip-if = ["debug"] # Bug 1507251 - Leak
skip-if = [ skip-if = [
"os == 'linux'", "os == 'linux'",
"os == 'mac'", "os == 'mac'",
"os == 'win' && os_version == '10.0'", # Bug 1514425 "os == 'win' && os_version == '10.2009'", # Bug 1514425
] ]
["test_currency_amount_validation.html"] ["test_currency_amount_validation.html"]

View file

@ -677,6 +677,9 @@ function BuildConditionSandbox(aURL) {
sandbox.d2d && sandbox.d2d &&
sandbox.gpuProcess; sandbox.gpuProcess;
sandbox.mozinfo = Services.prefs.getStringPref("sandbox.mozinfo", null);
sandbox.os_version = sandbox.mozinfo.os_version;
sandbox.layersGPUAccelerated = g.windowUtils.layerManagerType != "Basic"; sandbox.layersGPUAccelerated = g.windowUtils.layerManagerType != "Basic";
sandbox.d3d11 = g.windowUtils.layerManagerType == "Direct3D 11"; sandbox.d3d11 = g.windowUtils.layerManagerType == "Direct3D 11";
sandbox.d3d9 = g.windowUtils.layerManagerType == "Direct3D 9"; sandbox.d3d9 = g.windowUtils.layerManagerType == "Direct3D 9";

View file

@ -462,6 +462,9 @@ class RefTest(object):
# config specific flags # config specific flags
prefs["sandbox.apple_silicon"] = mozinfo.info.get("apple_silicon", False) prefs["sandbox.apple_silicon"] = mozinfo.info.get("apple_silicon", False)
prefs["sandbox.mozinfo"] = json.dumps(mozinfo.info)
prefs["sandbox.os_version"] = mozinfo.info.get("os_version", "")
# Set tests to run or manifests to parse. # Set tests to run or manifests to parse.
if tests: if tests:
testlist = os.path.join(profile.profile, "reftests.json") testlist = os.path.join(profile.profile, "reftests.json")

View file

@ -65,7 +65,13 @@ if system in ["Microsoft", "Windows"]:
version = "%d.%d.%d" % (major, minor, build_number) version = "%d.%d.%d" % (major, minor, build_number)
if major == 10 and minor == 0 and build_number >= 22000: if major == 10 and minor == 0 and build_number >= 22000:
major = 11 major = 11
os_version = "%d.%d" % (major, minor)
# 2009 == 22H2 software update. These are the build numbers
# we use 2009 as the "build" which maps to what taskcluster tasks see
if build_number == 22621 or build_number == 19045:
build_number = 2009
os_version = "%d.%d" % (major, build_number)
elif system.startswith(("MINGW", "MSYS_NT")): elif system.startswith(("MINGW", "MSYS_NT")):
# windows/mingw python build (msys) # windows/mingw python build (msys)
info["os"] = "win" info["os"] = "win"
@ -107,7 +113,7 @@ elif system == "Darwin":
(release, versioninfo, machine) = platform.mac_ver() (release, versioninfo, machine) = platform.mac_ver()
version = "OS X %s" % release version = "OS X %s" % release
versionNums = release.split(".")[:2] versionNums = release.split(".")[:2]
os_version = "%s.%s" % (versionNums[0], versionNums[1]) os_version = "%s.%s" % (versionNums[0], versionNums[1].ljust(2, "0"))
info["os"] = "mac" info["os"] = "mac"
elif sys.platform in ("solaris", "sunos5"): elif sys.platform in ("solaris", "sunos5"):
info["os"] = "unix" info["os"] = "unix"
@ -277,8 +283,8 @@ def find_and_update_from_json(*dirs, **kwargs):
except (BuildEnvironmentNotFoundException, MozconfigFindException): except (BuildEnvironmentNotFoundException, MozconfigFindException):
pass pass
for d in dirs: for dir in dirs:
d = _os.path.abspath(d) d = _os.path.abspath(dir)
json_path = _os.path.join(d, "mozinfo.json") json_path = _os.path.join(d, "mozinfo.json")
if _os.path.isfile(json_path): if _os.path.isfile(json_path):
update(json_path) update(json_path)

View file

@ -11,7 +11,6 @@ support-files = ["xul_tooltiptext.xhtml"]
["browser_bug581947.js"] ["browser_bug581947.js"]
["browser_input_file_tooltips.js"] ["browser_input_file_tooltips.js"]
skip-if = ["os == 'win' && os_version == '10.0'"] # Permafail on Win 10 (bug 1400368)
["browser_nac_tooltip.js"] ["browser_nac_tooltip.js"]

View file

@ -96,7 +96,7 @@ https_first_disabled = true # Bug 1737265
["browser_doorhanger_installs.js"] ["browser_doorhanger_installs.js"]
https_first_disabled = true # Bug 1737265 https_first_disabled = true # Bug 1737265
skip-if = [ skip-if = [
"os == 'win' && os_version == '10.0' && bits == 64", #Bug 1615449 "os == 'win' && os_version == '10.2009' && bits == 64", #Bug 1615449
] ]
["browser_empty.js"] ["browser_empty.js"]