Hello everyone,
I'm experiencing an issue while trying to lazy load files during tests.
I have this subscription module which is a submodule of my app module (which has oc.lazyLoad as dependency).
(I am using gulp-annotate, but I don't think that this is the problem. In any case you have the link if you want to check out the code).
app/subscription/v2/offer/offer.specs.js
describe('Service: OfferService', function () {
beforeEach(module('app', 'app.subscription'));
....
When I try to launch Karma here's what I see:
Error: [$injector:modulerr] Failed to instantiate module app.subscription due to:
Error: [$injector:modulerr] Failed to instantiate module {"files":["app/subscription/add-payment-method/credit-card/credit-card.component.js","app/subscription/add-payment-method/payment-method.component.js","app/subscription/add-payment-method/paypal/paypal.component.js","app/subscription/edit-payment-method/credit-card/credit-card.component.js","app/subscription/edit-payment-method/edit-payment-method.controller.js","app/subscription/edit-payment-method/edit-payment-method.service.js","app/subscription/edit-payment-method/paypal/paypal.component.js","app/subscription/v2/activate/activate.controller.js","app/subscription/v2/activate/pricing.constant.js","app/subscription/v2/offer/billing-data/billing-data.component.js","app/subscription/v2/offer/current-plan/current-plan.component.js","app/subscription/v2/offer/edit-payment-method/edit-payment-method.controller.js","app/subscription/v2/offer/edit-payment-method/edit-payment-method.service.js","app/subscription/v2/offer/model/estimate-request.model.js","app/subscription/v2/offer/model/estimate-response.model.js","app/subscription/v2/offer/model/estimation.model.js","app/subscription/v2/offer/model/upgrade-request.model.js","app/subscription/v2/offer/offer.controller.js","app/subscription/v2/offer/offer.service.js","app/subscription/v2/offer/payment-method/payment-method.component.js","app/subscription/v2/offer/summary/summary.component.js","app/subscription/v2/offer/upgrade-plan/list.service.js","app/subscription/v2/offer/upgrade-plan/upgrade-plan.component.js","app/subscription/v2/renew/renew.controller.js","app/subscription/v2/renew/revew.service.js","app/subscription/v2/renew/upgrade-request.model.js","app/subscription/v2/review/billing-info-validation.service.js","app/subscription/v2/review/billing-info.model.js","app/subscription/v2/review/billing-info.service.js","app/subscription/v2/review/review.controller.js","app/subscription/v2/subscription.config.js","app/subscription/v2/subscription.controller.js","app/subscription/v2/thank-you/thank-you.controller.js","app/subscription/v2/upgrade/upgrade.controller.js"],"cache":false,"serie":true} due to:
Error: [ng:areq] Argument 'module' is not a function, got Object
Hello everyone, I'm experiencing an issue while trying to lazy load files during tests. I have this subscription module which is a submodule of my app module (which has oc.lazyLoad as dependency).
app/subscription/subscription.module.js
(I am using gulp-annotate, but I don't think that this is the problem. In any case you have the link if you want to check out the code).
app/subscription/v2/offer/offer.specs.js
When I try to launch Karma here's what I see:
What am I supposed to do to make this work?
Thank you in advance, Manuel