Bug 1829412 - Simplify NimbusTestUtils.enrollmentHelper r=chumphreys,settings-reviewers,pip-reviewers,credential-management-reviewers,search-reviewers,anti-tracking-reviewers,omc-reviewers,home-newtab-reviewers,thecount,issammani,aminomancer,mconley
The enrollmentHelper was much more complicated than it needed to be. The internal asynchrony that required awaiting an additional promise was fixed in bug 1773583. The returned cleanup function is no longer async, so unnecessary awaits have been removed. This also applies to enrollWithFeatureConfig, as it is a wrapper around enrollmentHelper. Differential Revision: https://phabricator.services.mozilla.com/D212318
This commit is contained in:
@@ -38,7 +38,7 @@ add_task(async function remote_disable() {
|
||||
"Pinning disabled via nimbus"
|
||||
);
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function restore_default() {
|
||||
|
||||
@@ -80,7 +80,7 @@ add_task(async function remote_disable() {
|
||||
);
|
||||
Assert.ok(setDefaultStub.called, "Used plain set default insteead");
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function restore_default() {
|
||||
@@ -144,5 +144,5 @@ add_task(async function ensure_fallback() {
|
||||
);
|
||||
Assert.ok(setDefaultStub.called, "Fallbacked to plain set default");
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
@@ -87,7 +87,7 @@ add_task(async function remoteEnableWithPDF() {
|
||||
[".pdf", "FirefoxPDF"],
|
||||
]);
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function remoteEnableWithPDF_testOnlyReplaceBrowsers() {
|
||||
@@ -149,7 +149,7 @@ add_task(async function remoteEnableWithPDF_testOnlyReplaceBrowsers() {
|
||||
`Will not take default from non-browser`
|
||||
);
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function remoteEnableWithoutPDF() {
|
||||
@@ -181,7 +181,7 @@ add_task(async function remoteEnableWithoutPDF() {
|
||||
Assert.ok(setDefaultBrowserUserChoiceStub.called);
|
||||
Assert.deepEqual(setDefaultBrowserUserChoiceStub.firstCall.args, [aumi, []]);
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function remoteDisable() {
|
||||
@@ -212,7 +212,7 @@ add_task(async function remoteDisable() {
|
||||
Assert.ok(setDefaultBrowserUserChoiceStub.notCalled);
|
||||
Assert.ok(setDefaultStub.called);
|
||||
|
||||
await doCleanup();
|
||||
doCleanup();
|
||||
});
|
||||
|
||||
add_task(async function test_setAsDefaultPDFHandler_knownBrowser() {
|
||||
|
||||
Reference in New Issue
Block a user