DEV: Remove unnecessary test setup calls (#14940)

`setURLContainer()` and `setDefaultOwner()` are already called in an application initializer at the beginning of each test.
This commit is contained in:
Jarek Radosz 2021-11-15 13:46:09 +01:00 committed by GitHub
parent 985d079e47
commit 67e38e81f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,14 +4,14 @@ import {
clearCache as clearOutletCache,
resetExtraClasses,
} from "discourse/lib/plugin-connectors";
import { clearRewrites, setURLContainer } from "discourse/lib/url";
import { clearRewrites } from "discourse/lib/url";
import {
currentSettings,
mergeSettings,
} from "discourse/tests/helpers/site-settings";
import { forceMobile, resetMobile } from "discourse/lib/mobile";
import { getApplication, getContext, settled } from "@ember/test-helpers";
import { getOwner, setDefaultOwner } from "discourse-common/lib/get-owner";
import { getOwner } from "discourse-common/lib/get-owner";
import { later, run } from "@ember/runloop";
import { moduleFor, setupApplicationTest } from "ember-qunit";
import { Promise } from "rsvp";
@ -251,8 +251,6 @@ export function acceptance(name, optionsOrCallback) {
});
}
setURLContainer(this.container);
setDefaultOwner(this.container);
if (!this.owner) {
this.owner = this.container;
}
@ -291,8 +289,6 @@ export function acceptance(name, optionsOrCallback) {
clearNavItems();
setTopicList(null);
_clearSnapshots();
setURLContainer(null);
setDefaultOwner(null);
cleanUpComposerUploadHandler();
cleanUpComposerUploadProcessor();
cleanUpComposerUploadMarkdownResolver();