mirror of
https://github.com/discourse/discourse.git
synced 2025-05-29 00:00:46 +08:00
DEV: introduces prettier for es6 files
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
import componentTest from 'helpers/component-test';
|
||||
import Topic from 'discourse/models/topic';
|
||||
import componentTest from "helpers/component-test";
|
||||
import Topic from "discourse/models/topic";
|
||||
|
||||
const buildTopic = function() {
|
||||
return Topic.create({
|
||||
@ -10,15 +10,15 @@ const buildTopic = function() {
|
||||
});
|
||||
};
|
||||
|
||||
moduleForComponent('pinned-options', {
|
||||
moduleForComponent("pinned-options", {
|
||||
integration: true,
|
||||
beforeEach: function() {
|
||||
this.set('subject', selectKit());
|
||||
this.set("subject", selectKit());
|
||||
}
|
||||
});
|
||||
|
||||
componentTest('updating the content refreshes the list', {
|
||||
template: '{{pinned-options value=pinned topic=topic}}',
|
||||
componentTest("updating the content refreshes the list", {
|
||||
template: "{{pinned-options value=pinned topic=topic}}",
|
||||
|
||||
beforeEach() {
|
||||
this.siteSettings.automatically_unpin_topics = false;
|
||||
@ -28,13 +28,23 @@ componentTest('updating the content refreshes the list', {
|
||||
|
||||
test(assert) {
|
||||
andThen(() => {
|
||||
assert.equal(this.get('subject').header().name(), "pinned");
|
||||
assert.equal(
|
||||
this.get("subject")
|
||||
.header()
|
||||
.name(),
|
||||
"pinned"
|
||||
);
|
||||
});
|
||||
|
||||
andThen(() => this.set("pinned", false));
|
||||
|
||||
andThen(() => {
|
||||
assert.equal(this.get('subject').header().name(), "unpinned");
|
||||
assert.equal(
|
||||
this.get("subject")
|
||||
.header()
|
||||
.name(),
|
||||
"unpinned"
|
||||
);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user