This commit is contained in:
parent
132cfef4e9
commit
bae70e24f8
|
@ -2,16 +2,18 @@ import './left-menu.js';
|
|||
|
||||
describe('Component vnLeftMenu', () => {
|
||||
let controller;
|
||||
let $element;
|
||||
|
||||
beforeEach(angular.mock.module('salix', $translateProvider => {
|
||||
$translateProvider.translations('en', {});
|
||||
}));
|
||||
|
||||
beforeEach(angular.mock.inject(($componentController, $state, $window) => {
|
||||
$element = angular.element('<div></div>');
|
||||
$state.current.name = 'client.card.summary';
|
||||
$state.current.data = {moduleIndex: 0};
|
||||
$window.routes = [{menu: []}];
|
||||
controller = $componentController('vnLeftMenu', {$state, $window});
|
||||
controller = $componentController('vnLeftMenu', {$state, $window, $element});
|
||||
controller.items = [
|
||||
{description: 'Client', state: 'client', icon: null, childs: []},
|
||||
{description: 'Client', state: 'client.card', icon: null, childs: []},
|
||||
|
|
Loading…
Reference in New Issue