Posts by Aléxia • 305 points
12 posts
-
0
votes2
answers39
viewsA: How to apply the Hover method in my class?
I was able to solve it this way: <table id="tableData" class="table table-hover"> Modified in row 33
-
0
votes2
answers39
viewsQ: How to apply the Hover method in my class?
I have the following code: <section class="content-header"> <h1><i class="fa" ng-class="{'fa-tasks': !isCodeError, 'fa-remove': isCodeError}"></i> {{t(title)}}</h1>…
-
3
votes0
answers161
viewsQ: Testing a Trial in Angularjs
I am trying to apply unit test on the following function: function do_query(method, url, data, callback){ var defer = $q.defer(); var header_request = StorageService[storage].get('header_request');…
-
3
votes0
answers909
viewsQ: Typeerror: Undefined is not an Object (evaluating 'self.data.ID')
I’m trying to apply unit testing to my function onPersistSuccess, but this error appears Typeerror: Undefined is not an Object (evaluating 'self.data.ID') I have tried to define it in several ways…
-
1
votes0
answers731
viewsQ: How to fix error: Syntaxerror: JSON Parse error: Unexpected Identifier "Undefined"
I am getting the following error while trying to test my function: Syntaxerror: JSON Parse error: Unexpected Identifier "Undefined" The function is this: function onGetInstanceName(e, args) {…
-
1
votes0
answers80
viewsQ: How to solve a problem in Angularjs
I have the following function onLogin and within it I have a Promise being called on Loginservice how do I pass a unit test in this trial? function onLogin(e, args) { DebugMode &&…
-
0
votes1
answer58
viewsQ: How to validate defaultPrevented = false in my Angularjs test?
I have the following function: (function () { 'use strict'; angular.module("app") .service('EventHandler', EventHandler); EventHandler.$inject = ['$rootScope', '$location', '$animate', '$state',…
-
6
votes1
answer5709
viewsQ: How to use $broadcast(), $Emit() and $on() in Angularjs
I understood that the $emit() and the $broadcast are emitters and the $on is an event manager. I am working with unit tests and am unable to access the following function: eventHandler.service.js…
-
2
votes0
answers43
viewsQ: Undefined is not a constructor (evaluating 'Permissionsservice.isPermitted(Entity,crud_check)') thrown
Function: function checkPermissions(entity, crud_check, msg, title, state_redirect, paramsRedirect) { try { if (PermissionsService.isPermitted(entity, crud_check) === false) { showToastrError(title,…
-
0
votes0
answers537
viewsQ: Error: [$injector:unpr] Unknown Provider: $scopeProvider <- $Scope
I am getting the following error while running my test: Error: [$injector:unpr] Unknown Provider: $scopeProvider <- $Scope Logincontroller.js (function(){ 'use strict'; angular.module("app")…
-
1
votes0
answers338
viewsQ: How to use $rootScope. $on?
I don’t know how to set $rootScope. $on on my unit test. Whenever I invoke a function it gives me the following error: Typeerror: Attempted to assign to readonly Property. The test is being done as…
-
1
votes0
answers30
viewsQ: By a defined object is giving the indefinite error in Angularjs
I am getting an error by performing the following test: it('testing if the onStateChangeErrorHandle function is defined', function(){ expect(rootScope.$on).toBeDefined();…