fix comment spec, jasmine should be ok now

This commit is contained in:
Florian Staudacher 2014-02-18 11:14:02 +01:00
parent e3b22ed95c
commit 69a1718d08
2 changed files with 7 additions and 2 deletions

View file

@ -53,7 +53,7 @@ describe("app.views.CommentStream", function(){
});
it("adds the comment to the view", function() {
this.request.response({status: 200});
this.request.response({status: 200, responseText: '[]'});
expect(this.view.$(".comment-content p").text()).toEqual("a new comment");
});

View file

@ -84,7 +84,12 @@ describe("app.views.Header", function() {
describe("focus", function() {
it("adds the class 'active' when the user focuses the text field", function() {
input.trigger('focus');
expect(input).toHaveClass("active");
waitsFor(function() {
return input.is('.active');
});
runs(function() {
expect(input).toHaveClass("active");
});
});
});