DEV: Remove some extra Discourse.Site uses
This commit is contained in:
@@ -2,6 +2,7 @@ import { run } from "@ember/runloop";
|
||||
import createStore from "helpers/create-store";
|
||||
import NavItem from "discourse/models/nav-item";
|
||||
import Category from "discourse/models/category";
|
||||
import Site from "discourse/models/site";
|
||||
|
||||
QUnit.module("NavItem", {
|
||||
beforeEach() {
|
||||
@@ -10,7 +11,7 @@ QUnit.module("NavItem", {
|
||||
name: "确实是这样",
|
||||
id: 343434
|
||||
});
|
||||
Discourse.Site.currentProp("categories").addObject(asianCategory);
|
||||
Site.currentProp("categories").addObject(asianCategory);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
import createStore from "helpers/create-store";
|
||||
import Site from "discourse/models/site";
|
||||
|
||||
QUnit.module("model:site");
|
||||
|
||||
QUnit.test("create", assert => {
|
||||
assert.ok(Discourse.Site.create(), "it can create with no parameters");
|
||||
assert.ok(Site.create(), "it can create with no parameters");
|
||||
});
|
||||
|
||||
QUnit.test("instance", assert => {
|
||||
const site = Discourse.Site.current();
|
||||
const site = Site.current();
|
||||
|
||||
assert.present(site, "We have a current site singleton");
|
||||
assert.present(
|
||||
|
||||
Reference in New Issue
Block a user