diff --git a/spec/javascripts/right_sidebar_spec.js b/spec/javascripts/right_sidebar_spec.js index b2ee0ce5963..0177d8e4e79 100644 --- a/spec/javascripts/right_sidebar_spec.js +++ b/spec/javascripts/right_sidebar_spec.js @@ -65,9 +65,10 @@ }); it('should broadcast todo:toggle event when add todo clicked', function() { + var todos = getJSONFixture('todos.json'); spyOn(jQuery, 'ajax').and.callFake(function() { var d = $.Deferred(); - var response = getJSONFixture('todos.json'); + var response = todos; d.resolve(response); return d.promise(); });