Files
habitica/test/client-old/spec/controllers/menuCtrlSpec.js
2016-09-15 13:05:23 +02:00

27 lines
675 B
JavaScript

'use strict';
describe('Menu Controller', function() {
describe('MenuCtrl', function(){
var scope, ctrl, user, $httpBackend, $window;
beforeEach(function(){
module(function($provide) {
$provide.value('Chat', { seenMessage: function() {} });
});
inject(function(_$httpBackend_, $rootScope, $controller) {
scope = $rootScope.$new();
ctrl = $controller('MenuCtrl', {$scope: scope, $window: $window, User: user});
})
});
describe('clearMessage', function() {
it('is Chat.seenMessage', inject(function(Chat) {
expect(scope.clearMessages).to.eql(Chat.markChatSeen);
}));
});
});
});