mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Test only change / possible fix for Bug 759639 - Intermittent test_0202_app_launch_apply_update_dirlocked_svc.js | test failed (with xpcshell return code: 0), | pending-service == pending, | exception thrown from do_timeout callback: 2147500036. r=bbondy
This commit is contained in:
parent
e0a186179f
commit
924a29af19
@ -448,12 +448,26 @@ function cleanUpdatesDir(aDir) {
|
||||
}
|
||||
cleanUpdatesDir(entry);
|
||||
entry.permissions = PERMS_DIRECTORY;
|
||||
entry.remove(true);
|
||||
try {
|
||||
entry.remove(true);
|
||||
}
|
||||
catch (e) {
|
||||
dump("Unable to remove directory\npath: " + entry.path +
|
||||
"\nException: " + e + "\n");
|
||||
throw(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
entry.permissions = PERMS_FILE;
|
||||
entry.remove(false);
|
||||
try {
|
||||
entry.remove(false);
|
||||
}
|
||||
catch (e) {
|
||||
dump("Unable to remove file\npath: " + entry.path + "\nException: " +
|
||||
e + "\n");
|
||||
throw(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -434,6 +434,7 @@ if (IS_WIN) {
|
||||
file.QueryInterface(AUS_Ci.nsILocalFileWin);
|
||||
file.fileAttributesWin |= file.WFA_READONLY;
|
||||
file.fileAttributesWin &= ~file.WFA_READWRITE;
|
||||
logTestInfo("testing the successful creation of the lock file");
|
||||
do_check_true(file.exists());
|
||||
do_check_false(file.isWritable());
|
||||
}
|
||||
@ -446,6 +447,7 @@ if (IS_WIN) {
|
||||
file.QueryInterface(AUS_Ci.nsILocalFileWin);
|
||||
file.fileAttributesWin |= file.WFA_READWRITE;
|
||||
file.fileAttributesWin &= ~file.WFA_READONLY;
|
||||
logTestInfo("removing and testing the successful removal of the lock file");
|
||||
file.remove(false);
|
||||
do_check_false(file.exists());
|
||||
}
|
||||
@ -1433,18 +1435,19 @@ function removeCallbackCopy() {
|
||||
appBinCopy.append(TEST_ID + FILE_WIN_TEST_EXE);
|
||||
if (appBinCopy.exists()) {
|
||||
try {
|
||||
logTestInfo("attempting removal of file: " + appBinCopy.path);
|
||||
appBinCopy.remove(false);
|
||||
// Use a timeout to give any files that were in use additional
|
||||
// time to close. Same as updater.exe without service tests.
|
||||
do_timeout(TEST_HELPER_TIMEOUT, do_test_finished);
|
||||
}
|
||||
catch (e) {
|
||||
logTestInfo("unable to remove file during cleanup. Exception: " + e);
|
||||
logTestInfo("non-fatal error removing file during cleanup (will try " +
|
||||
"again). File: " + appBinCopy.path + " Exception: " + e);
|
||||
do_timeout(TEST_HELPER_TIMEOUT, removeCallbackCopy);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
do_timeout(TEST_HELPER_TIMEOUT, do_test_finished);
|
||||
}
|
||||
// Use a timeout to give any files that were in use additional
|
||||
// time to close. Same as updater.exe without service tests.
|
||||
do_timeout(TEST_HELPER_TIMEOUT, do_test_finished);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -130,7 +130,7 @@ function run_test() {
|
||||
|
||||
let channel = Services.prefs.getCharPref(PREF_APP_UPDATE_CHANNEL);
|
||||
let patches = getLocalPatchString(null, null, null, null, null, "true",
|
||||
STATE_PENDING);
|
||||
STATE_PENDING_SVC);
|
||||
let updates = getLocalUpdateString(patches, null, null, null, null, null,
|
||||
null, null, null, null, null, null,
|
||||
null, "true", channel);
|
||||
@ -543,5 +543,6 @@ function checkUpdateFinished() {
|
||||
logTestInfo("testing " + updatesDir.path + " should exist");
|
||||
do_check_true(updatesDir.exists());
|
||||
|
||||
removeCallbackCopy();
|
||||
// Give the callback app time to close before trying to delete it.
|
||||
do_timeout(TEST_HELPER_TIMEOUT, removeCallbackCopy);
|
||||
}
|
||||
|
@ -130,7 +130,7 @@ function run_test() {
|
||||
|
||||
let channel = Services.prefs.getCharPref(PREF_APP_UPDATE_CHANNEL);
|
||||
let patches = getLocalPatchString(null, null, null, null, null, "true",
|
||||
STATE_PENDING);
|
||||
STATE_PENDING_SVC);
|
||||
let updates = getLocalUpdateString(patches, null, null, null, null, null,
|
||||
null, null, null, null, null, null,
|
||||
null, "true", channel);
|
||||
|
@ -138,7 +138,7 @@ function run_test() {
|
||||
|
||||
let channel = Services.prefs.getCharPref(PREF_APP_UPDATE_CHANNEL);
|
||||
let patches = getLocalPatchString(null, null, null, null, null, "true",
|
||||
STATE_PENDING);
|
||||
STATE_PENDING_SVC);
|
||||
let updates = getLocalUpdateString(patches, null, null, null, null, null,
|
||||
null, null, null, null, null, null,
|
||||
null, "true", channel);
|
||||
|
Loading…
Reference in New Issue
Block a user