Backed out 1 changesets (bug 1411093) for failing xpcshell in toolkit/components/telemetry/tests/unit/test_TelemetryLog.js r=backout on a CLOSED TREE.

Backed out changeset 2b8628840dfe (bug 1411093)
This commit is contained in:
Attila Craciun 2017-10-25 12:02:11 +03:00
parent 01ead6c2f2
commit 0e9f5ef014
18 changed files with 19 additions and 8 deletions

View File

@ -342,14 +342,6 @@ if (runningInParent) {
// Turn off Health Ping submission.
Services.prefs.setBoolPref(TelemetryUtils.Preferences.HealthPingEnabled, false);
// Non-unified Telemetry (e.g. Fennec on Android) needs the preference to be set
// in order to enable Telemetry.
if (Services.prefs.getBoolPref(TelemetryUtils.Preferences.Unified, false)) {
Services.prefs.setBoolPref(TelemetryUtils.Preferences.TelemetryEnabled, true);
} else {
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
}
fakePingSendTimer((callback, timeout) => {
Services.tm.dispatchToMainThread(() => callback());
},

View File

@ -75,6 +75,7 @@ add_task(async function() {
do_get_profile(true);
loadAddonManager(APP_ID, APP_NAME, APP_VERSION, PLATFORM_VERSION);
finishAddonManagerStartup();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
await TelemetryController.testSetup();
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();

View File

@ -91,6 +91,7 @@ add_task(async function() {
// Setup.
do_get_profile(true);
loadAddonManager(APP_ID, APP_NAME, APP_VERSION, PLATFORM_VERSION);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
finishAddonManagerStartup();
await TelemetryController.testSetup();
if (runningInParent) {

View File

@ -140,6 +140,7 @@ add_task(async function() {
// Setup.
do_get_profile(true);
loadAddonManager(APP_ID, APP_NAME, APP_VERSION, PLATFORM_VERSION);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
finishAddonManagerStartup();
await TelemetryController.testSetup();
if (runningInParent) {

View File

@ -68,6 +68,7 @@ add_task(async function test_setup() {
do_get_profile(true);
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
});
add_task(async function test_archivedPings() {

View File

@ -40,6 +40,7 @@ add_task(async function setup() {
// Init the profile.
do_get_profile(true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.FhrUploadEnabled, true);
// Start the ping server and let Telemetry know about it.

View File

@ -90,6 +90,8 @@ add_task(async function test_setup() {
finishAddonManagerStartup();
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Preferences.set(TelemetryUtils.Preferences.OverridePreRelease, true);
});
add_task(async function test_subsessionsChaining() {

View File

@ -183,5 +183,6 @@ add_task({
function run_test() {
do_get_profile(true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
run_next_test();
}

View File

@ -96,6 +96,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.FhrUploadEnabled, true);
await new Promise(resolve =>

View File

@ -30,6 +30,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.FhrUploadEnabled, true);
});

View File

@ -19,6 +19,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.FhrUploadEnabled, true);
// Start the webserver to check if the pending ping correctly arrives.

View File

@ -53,6 +53,7 @@ add_task(async function setup() {
do_get_profile(true);
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref("toolkit.telemetry.enabled", true);
Preferences.set(TelemetryUtils.Preferences.HealthPingEnabled, true);
await TelemetryController.testSetup();

View File

@ -27,6 +27,7 @@ function check_event(event, id, data) {
add_task(async function() {
do_get_profile();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
await TelemetryController.testSetup();
TelemetryLog.log(TEST_PREFIX + "1", ["val", 123, undefined]);

View File

@ -57,6 +57,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
// Don't bypass the notifications in this test, we'll fake it.
Services.prefs.setBoolPref(TelemetryUtils.Preferences.BypassNotification, false);

View File

@ -84,6 +84,7 @@ add_task(async function test_setup() {
do_get_profile(true);
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.HealthPingEnabled, true);
TelemetryStopwatch.setTestModeEnabled(true);
});

View File

@ -148,6 +148,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setCharPref(TelemetryUtils.Preferences.Server,
"http://localhost:" + PingServer.port);
});

View File

@ -478,6 +478,7 @@ add_task(async function test_setup() {
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
Services.prefs.setBoolPref(TelemetryUtils.Preferences.FhrUploadEnabled, true);
// Make it look like we've previously failed to lock a profile a couple times.

View File

@ -13,6 +13,8 @@ add_task(async function test_setup() {
finishAddonManagerStartup();
// Make sure we don't generate unexpected pings due to pref changes.
await setEmptyPrefWatchlist();
Services.prefs.setBoolPref(TelemetryUtils.Preferences.OverridePreRelease, true);
});
add_task(async function test_record_activeTicks() {