Questions tagged [jasmine2.0]

Jasmine is an open source testing framework for JavaScript. It aims to run on any JavaScript-enabled platform, to not intrude on the application nor the IDE, and to have easy-to-read syntax. It is heavily influenced by other unit testing frameworks, such as ScrewUnit, JSSpec, JSpec, and RSpec.

Jasmine is an open source testing framework for JavaScript. It aims to run on any JavaScript-enabled platform, to not intrude on the application nor the IDE, and to have easy-to-read syntax. It is heavily influenced by other unit testing frameworks, such as ScrewUnit, JSSpec, JSpec, and RSpec.

197 questions
0
votes
0 answers

Time out exception is displaying while running "Protractor test script" in "internet explorer" browser

I am unable to run "protractor test script" in "Internet explorer" browser. I run below command. webdriver-manager update --ie --versions.standalone 3.4.0 --versions.ie 3.4.0 my configuration file code is as below. exports.config = { …
Aswini
  • 3
  • 4
0
votes
0 answers

Protractor baseurl reloading the page multiple times before starting the test specs

Everytime I run the protractor command,the baseurl is reloading multiple times before starting actual test specs.Sometimes its reloading 2 times sometimes its 4-5 times. exports.config = { plugins: [{ package: 'protractor-console', …
Nikhita
  • 11
  • 3
0
votes
1 answer

Error while using "Protractor jasmine 2 screen shot reporter"

I am trying to take the "Screen shot" of the web page when the "test case fails". I installed "protractor-jasmine2-screenshot-reporter" using "npm". I am using below data. 1.Node -- v6.11.4 2.NPM -- 3.10.10 3.Protractor -- 5.1.2 My…
vasundhara
  • 109
  • 2
  • 10
0
votes
1 answer

Promises are not waiting resolve in jasmineDone

I am trying to post the result on testrail portal but this thing doesn't seem to be working. I am using this plugin https://www.npmjs.com/package/testrail-api and trying to do it in jasmine custom reporter which is jasmineDone: function () { …
Ajay Suwalka
  • 549
  • 1
  • 7
  • 24
0
votes
1 answer

How to use jasmine to mock jquery getJSON callback

I have module that contains a load function and that load function calls jQuery's getJSON function load(key,callback){ // validate inputs $.getJSON( this.data[key],'',function(d){ switch(key){ // do some stuff with the data based…
Wanderer
  • 544
  • 1
  • 7
  • 23
0
votes
0 answers

Accessing the view which has the dependecy

I have two js files, in which one view in a separate file. I am testing it using Jasmine unit testing. I have the js files included in the jasmine.html page. I am able to access everything other than the following view. The problem I am facing is…
purnima
  • 9
  • 1
0
votes
1 answer

Unit Test are not failing

I am trying to write unit test cases, for web API call. Which shows success below : Success Unit Test (jsfiddle) getProduct("jsonp","https://maps.googleapis.com/maps/api/e Error Unit Test (jsfiddle) But still its shows "pass" …
SmartestVEGA
  • 8,415
  • 26
  • 86
  • 139
0
votes
1 answer

Karma/Jasmine how to call a method on an angularjs Factory

I need some help getting this test to run. I've spent way to much time on it. So i am stuck and need some help? I simply have a factory method, that has one method and i keep getting [Unable to get property 'method1' of undefined or null reference…
muscleman71
  • 91
  • 2
  • 13
0
votes
1 answer

Protractor + Typescript + async/await: Failed - Wait timed out after 10001ms

It seems that it doesn't work as it should. Failed: Wait timed out after 10012ms I tried a lot of cases of waits but anyway stack trace gets a timeout error. How to possible manage it? Here is my code: (waiter.ts) import {browser, element,…
0
votes
1 answer

How to report posted payment is completed or skipped or failed in protractor

As my application has a payment status that changes every time based on settings, i wanted to publish in a report that for this test cases payment made is completed. Here is the code-
Smitha
  • 27
  • 6
0
votes
0 answers

Jasmine 2 - Get total success and fail specs and set it into a var

Is there a way to get the count of the success and failed specs? for example: onComplete: function() { console.log(jasmine.SUCCESS, jasmine.FAILURES); } Something like that. I use the following libraries protractor-jasmine2-html-reporter…
Archagy
  • 135
  • 1
  • 12
0
votes
1 answer

Async Test in Jasmine 2.6

The syntax for async tests has changed since 2.x and the documentation is not clear. Can someone clarify how I execute some code, block for 3 seconds, and then run a test condition using the new syntax? it('should update the table when new data is…
Robatron
  • 126
  • 10
0
votes
0 answers

Karma-Jasmine setup for Angular project

I have an angular(currently @4.0.0) project for which I want to introduce Unit Testing using Karma and Jasmine. I have set up the appropriate karma.conf.js, spec-bundle.js and package.json. But when I run npm test, this is what is on the console.…
user3344978
  • 644
  • 1
  • 8
  • 22
0
votes
1 answer

how to get total specs count and pass and fail specs count in jasmine 2 and protractor

I want to generate the emailable report after my test suite gets completed using Jasmine and protractor. How can I get the following information after my test suite is completed. 1.Total no of spec count 2.Total pass spec count 3.Total Failed test…
0
votes
0 answers

Jasmine error while running protractor test through tfs

I am trying to run protractor through tfs from a sln my local dev dept made. I am able to successfully run these tests locally and through eclipse however when I use the test the vs test explorer I get the below error ReferenceError: browser is not…
Nicole Phillips
  • 753
  • 1
  • 18
  • 41