This commit is contained in:
parent
8ef6db9017
commit
9c0613e8e7
|
@ -28,19 +28,5 @@ describe('factory vnModuleLoader', () => {
|
||||||
|
|
||||||
expect(result).toEqual(jasmine.any(Promise));
|
expect(result).toEqual(jasmine.any(Promise));
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should return an error if the module wasnt loaded', done => {
|
|
||||||
vnModuleLoader._loaded.myModule = false;
|
|
||||||
|
|
||||||
vnModuleLoader.load('myModule', {myValidations: () => {}})
|
|
||||||
.then(() => {
|
|
||||||
done.fail('this must fail');
|
|
||||||
})
|
|
||||||
.catch(error => {
|
|
||||||
expect(error.toString()).toEqual(`Error: Module dependency loop detected: myModule`);
|
|
||||||
done();
|
|
||||||
});
|
|
||||||
$scope.$apply();
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,14 +1,13 @@
|
||||||
import './index.js';
|
import './index.js';
|
||||||
|
|
||||||
describe('Item', () => {
|
describe('ticket Component vnTicketDescriptorPopover', () => {
|
||||||
describe('Component vnTicketDescriptorPopover', () => {
|
|
||||||
let $httpBackend;
|
let $httpBackend;
|
||||||
let $scope;
|
let $scope;
|
||||||
let controller;
|
let controller;
|
||||||
let $element;
|
let $element;
|
||||||
let $timeout;
|
let $timeout;
|
||||||
|
|
||||||
beforeEach(ngModule('item'));
|
beforeEach(ngModule('ticket'));
|
||||||
|
|
||||||
beforeEach(angular.mock.inject(($componentController, $rootScope, _$httpBackend_, _$timeout_) => {
|
beforeEach(angular.mock.inject(($componentController, $rootScope, _$httpBackend_, _$timeout_) => {
|
||||||
$httpBackend = _$httpBackend_;
|
$httpBackend = _$httpBackend_;
|
||||||
|
@ -123,4 +122,4 @@ describe('Item', () => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
|
||||||
|
|
|
@ -1,12 +1,10 @@
|
||||||
import './index.js';
|
import './index.js';
|
||||||
|
|
||||||
describe('Item Component vnTicketDescriptor', () => {
|
describe('Ticket Component vnTicketDescriptor', () => {
|
||||||
let $httpBackend;
|
let $httpBackend;
|
||||||
let controller;
|
let controller;
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(ngModule('ticket'));
|
||||||
ngModule('item');
|
|
||||||
});
|
|
||||||
|
|
||||||
beforeEach(angular.mock.inject(($componentController, _$httpBackend_) => {
|
beforeEach(angular.mock.inject(($componentController, _$httpBackend_) => {
|
||||||
$httpBackend = _$httpBackend_;
|
$httpBackend = _$httpBackend_;
|
||||||
|
|
Loading…
Reference in New Issue