mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-07 11:48:19 +02:00
16 lines
398 B
JavaScript
16 lines
398 B
JavaScript
"use strict";
|
|
|
|
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
|
|
|
const EXPORTED_SYMBOLS = ["RegionTestUtils"];
|
|
|
|
const RegionTestUtils = Object.freeze({
|
|
REGION_URL_PREF: "browser.region.network.url",
|
|
|
|
setNetworkRegion(region) {
|
|
Services.prefs.setCharPref(
|
|
this.REGION_URL_PREF,
|
|
`data:application/json,{"country_code": "${region}"}`
|
|
);
|
|
},
|
|
});
|