diff options
Diffstat (limited to 'browser/components/enterprisepolicies/tests/browser/hardware_acceleration')
3 files changed, 23 insertions, 0 deletions
diff --git a/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser.toml b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser.toml new file mode 100644 index 0000000000..58b8322d72 --- /dev/null +++ b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser.toml @@ -0,0 +1,5 @@ +[DEFAULT] +prefs = ["browser.policies.alternatePath='<test-root>/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/disable_hardware_acceleration.json'"] +support-files = ["disable_hardware_acceleration.json"] + +["browser_policy_hardware_acceleration.js"] diff --git a/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser_policy_hardware_acceleration.js b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser_policy_hardware_acceleration.js new file mode 100644 index 0000000000..436bd410d1 --- /dev/null +++ b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/browser_policy_hardware_acceleration.js @@ -0,0 +1,13 @@ +/* Any copyright is dedicated to the Public Domain. + * http://creativecommons.org/publicdomain/zero/1.0/ */ + +"use strict"; + +add_task(async function test_policy_hardware_acceleration() { + let winUtils = Services.wm.getMostRecentWindow("").windowUtils; + let layerManager = winUtils.layerManagerType; + ok( + layerManager == "Basic" || layerManager == "WebRender (Software)", + "Hardware acceleration disabled" + ); +}); diff --git a/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/disable_hardware_acceleration.json b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/disable_hardware_acceleration.json new file mode 100644 index 0000000000..acbdc0a3f4 --- /dev/null +++ b/browser/components/enterprisepolicies/tests/browser/hardware_acceleration/disable_hardware_acceleration.json @@ -0,0 +1,5 @@ +{ + "policies": { + "HardwareAcceleration": false + } +} |