Add list view tests

Also,
 * moved fetch out of the list view
 * removed unused #last() function
 * put test setup lines in their own tiny file.
 * added data-cover to view script tags for code coveage reports.
This commit is contained in:
lilia
2014-09-04 00:16:06 -07:00
parent 4ccb2b2f98
commit db86abdf70
6 changed files with 43 additions and 18 deletions

View File

@@ -12,6 +12,7 @@ var Whisper = Whisper || {};
this.$el.html(Mustache.render(this.template));
this.view = new Whisper.MessageListView({collection: this.model.messages()});
this.model.messages().fetch({reset: true});
this.$el.find('.discussion-container').append(this.view.el);
},
events: {