FIX: Highlighting was not being applied after some rendering.

Also includes a bunch of ES6 stuff.
This commit is contained in:
Robin Ward
2015-02-12 15:37:02 -05:00
parent 96697c7957
commit a519fd5bcf
21 changed files with 314 additions and 503 deletions

View File

@ -1,5 +1,7 @@
module("Discourse.SelectedPostsCount");
import Topic from 'discourse/models/topic';
var buildTestObj = function(params) {
return Ember.Object.createWithMixins(Discourse.SelectedPostsCount, params || {});
};
@ -26,7 +28,7 @@ test("when all posts are selected and there is a posts_count", function() {
test("when all posts are selected and there is topic with a posts_count", function() {
var testObj = buildTestObj({
allPostsSelected: true,
topic: Discourse.Topic.create({ posts_count: 3456 })
topic: Topic.create({ posts_count: 3456 })
});
equal(testObj.get('selectedPostsCount'), 3456, "It returns the topic's posts_count");