mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
Repair remaining Karma specs - all passing.
* Stubbed out User module to repair rootCtrlSpec * Loaded RootCtrl in inventoryCtrlSpec, as it was missing shared functions. Updated mock user to include a mounts hash.
This commit is contained in:
@@ -1,17 +1,23 @@
|
||||
'use strict';
|
||||
|
||||
// @TODO: Something here is calling a full page reload
|
||||
xdescribe('Root Controller', function() {
|
||||
describe('Root Controller', function() {
|
||||
var scope, user, ctrl;
|
||||
|
||||
beforeEach(inject(function($rootScope, $controller) {
|
||||
scope = $rootScope.$new();
|
||||
scope.loginUsername = 'user'
|
||||
scope.loginPassword = 'pass'
|
||||
user = specHelper.newUser();
|
||||
beforeEach(function () {
|
||||
module(function($provide) {
|
||||
$provide.value('User', {});
|
||||
});
|
||||
|
||||
ctrl = $controller('RootCtrl', {$scope: scope, User: {user: user}});
|
||||
}));
|
||||
inject(function($rootScope, $controller) {
|
||||
scope = $rootScope.$new();
|
||||
scope.loginUsername = 'user'
|
||||
scope.loginPassword = 'pass'
|
||||
user = specHelper.newUser();
|
||||
|
||||
ctrl = $controller('RootCtrl', {$scope: scope, User: {user: user}});
|
||||
});
|
||||
});
|
||||
|
||||
it('shows contributor level text', function(){
|
||||
expect(scope.contribText()).to.eql(undefined);
|
||||
|
||||
Reference in New Issue
Block a user