зеркало из https://github.com/mozilla/gecko-dev.git
Bug 982201 - Don't give up so easily when constructing netmonitor statistics view during tests. r=past
In tests it doesn't make sense to give up after two seconds as we want to test the actual feature - not that it can do everything in under two seconds which is quite a long shot on debug builds. The new 45 second timeout during tests matches the 45 second timeout of mochitests which essentially makes it impossible for whenDataAvailable to timeout during tests causing these false positives.
This commit is contained in:
Родитель
d2b470167d
Коммит
269fbab986
|
@ -799,7 +799,12 @@ function whenDataAvailable(aDataStore, aMandatoryFields) {
|
|||
};
|
||||
|
||||
const WDA_DEFAULT_VERIFY_INTERVAL = 50; // ms
|
||||
const WDA_DEFAULT_GIVE_UP_TIMEOUT = 2000; // ms
|
||||
|
||||
// Use longer timeout during testing as the tests need this process to succeed
|
||||
// and two seconds is quite short on slow debug builds. The timeout here should
|
||||
// be at least equal to the general mochitest timeout of 45 seconds so that this
|
||||
// never gets hit during testing.
|
||||
const WDA_DEFAULT_GIVE_UP_TIMEOUT = gDevTools.testing ? 45000 : 2000; // ms
|
||||
|
||||
/**
|
||||
* Helper method for debugging.
|
||||
|
|
Загрузка…
Ссылка в новой задаче