Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [jasmine]

Jasmine is a behavior-driven development (BDD) framework for testing JavaScript code. Jasmine has no external dependencies and does not require a DOM.

1
vote
1answer
15 views

Can Jasmine tests be executed in a specific order?

I believe it is considered to be a bad practice to rely on the order in which the (acceptance) tests should be run, but for testing "deeply nested features" (I don't know if there is a standard term ...
0
votes
1answer
35 views

Unable to run protractor script

I'm not able to run my protractor tests. Getting the below error: grunt cltest Running "protractor:singlerun" (protractor) task (node:26770) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. ...
2
votes
1answer
255 views

How to use async/await with Protractor-nodejs8

I am completely new to protractor, and I came across the async/await. Is it necessary to use async/await in all your script. And how to use with page object. Using node version 8.9.4 protractor ...
2
votes
1answer
49 views

How does $( document ).ready() work?

I have started using jQuery and jasmine to automate webpage testing. From what I understand, by calling $( document ).ready() would make sure that a webpage would finish loading. But for the ...
3
votes
2answers
51 views

Protractor Image didnt upload on dialogue box?

I want to test the image upload functionality using Protractor but my written script didn't work. When we click on the dialogue box image it opens the window to select the desired image. After the ...
0
votes
1answer
235 views

Protractor - How to extract a link from HTML string?

In one of my test cases, I'm able to get the entire HTML e-mail message sent to a user. The message contains text, button, a link, etc. My Issue is that I need to extract the href link in order to ...
2
votes
1answer
650 views

E2E: Retrieve email-link - How to invoke callBack function for mailListener?

I do have an E2E test for retrieving confirmation email after registration. I need the link in the confirmation email to login the user as the link in the email contains the token etc. for access. ...
2
votes
1answer
2k views

Protractor: Firefox browser opens but URL is not launched

I am trying to run TestCase in Firefox browser. Result is : Firefox browser opens, but URL is not loading. FIREFOX browser - 53 Selenium- webdriver - 3.6.0 NPM - 3.10.10 Protractor ...
0
votes
0answers
337 views

Why I am getting code ELIFECYCLE Error in Test cases?

We have more than 2000 test cases in our source. To generate the code coverage in less time,I have implemented the parallel execution of test cases with npm-concurrently package and chrome headless ...
2
votes
1answer
2k views

Unable to run Protractor tests in Microsoft Edge

I'm working on a project to begin testing Node/Angular applications using Protractor and Jasmine. I have a POC working in most browsers but having a lot of trouble with MS Edge. Here's my ...
0
votes
1answer
414 views

Please help with simple test case in jasmine

I am stuck with jasmine. I read/youtubed/googled but seems like I am on the wrong track. Here is what I have so far. I've used protractor --elementExplorer to pull items from http://www.angular.io: &...
2
votes
0answers
92 views

How to check children method has been called in jasmine test cases?

We use spyOn(this,"_new") to track a function call in jasmine. I need to check the children method call in jasmine. My code sample is given below, Sample code: function perform(option) { this....
2
votes
2answers
596 views

Protractor: Specified suite is not running .Instead all suite inside Suites(config.js) is running

Test Case: I wanted to run only one suite (eg) suite 'A'. So i specified the same while running configuration protractor conf.js -- suites A Problem: All Suites (A,B,C,D) are running, instead of ...
1
vote
0answers
557 views

How to clear karma warn web-server 404 error for Service method call?

I am new to TDD. I have configured the karma and gulp for my sources to generate the code coverage. My karma configuration file is given below: browsers: ['Chrome', 'IE', 'Firefox', 'MyHeadlessChrome'...
1
vote
1answer
2k views

Protractor: How to get text present between two span

I want to get the text (SampleList23.csv) that is present between 2 spans. HTML: <div class="ng-scope" ng-switch-when="false"> <div class="engage-tag ng-binding"> <span ...
2
votes
0answers
410 views

How to expand upon the error from a Jasmine expect failure?

I'm using Jasmine, FrisbyJS, and Jest to create API tests for my team's product. I want to be able to handle when an expect (which I'm pretty sure Frisby is just using the underlying Jasmine expect) ...
5
votes
1answer
5k views

AngularJS testing with Protractor- no element found using locator

I have just recently started working on integrating a test framework into my AngularJS application, using Protractor do build the test cases & run the tests. Having never used automated testing ...
5
votes
1answer
975 views

Is there a way to run a subset of tests using Jest?

I would like to be able to run a subset of it's or describe's in a Jasmine test file using jest with some type of tagging system. I know I can indicate a filter of sorts by using a word after the ...
0
votes
1answer
2k views

Why am I getting “RangeError: Maximum call stack size exceeded” when I try to run FrisbyJS tests with Jest?

When I try to run my frisbyjs tests with jest as documented on the github page, I get the following error: RangeError: Maximum call stack size exceeded at String.slice (native) at Object....
2
votes
1answer
806 views

Parallel protractor tests are still running sequentially

Looking For: I want to run Specs in Parallel. Tried: Included in config file: shardTestFiles : true, maxInstances: 4 Output I see: Multiple instances are not opening. Still running in serial. **...
3
votes
2answers
389 views

Should I use Jasmine/FrisbyJS or Mocha/Chai for testing of live API with Angular?

What I'm looking for in an answer Concrete relevant(newer?) examples of why one choice is better than the other OR, a concrete suggestion of why using a different language is the better choice over ...
3
votes
0answers
361 views

Karma/ Jasmine testing framework - tests don't appear to be executed

I am looking to implement the Karma/ Jasmine test suite/ framework for use with my AngularJS app. Having never used a testing framework previously, I have followed the tutorial at: https://scotch.io/...
0
votes
1answer
1k views

How to verify that the menu items (tab/column Elements) are clickable? or Unclickable?

Test Case In My web page, I have 5 tabs (A,B,C,D,E) in which 2 tabs (A,B) are clickable and 3 Tabs(C,D,E) are not clickable. Write a script to verify those tab elements are clickable or not. What ...
6
votes
1answer
394 views

Why Phantomjs got crashed while running more test cases?

I have written 751 test cases in Jasmine JavaScript. 116 test cases for Mobile View and 645 test cases on Desktop view. While executing test cases, most of the times, test case execution was not ...
6
votes
2answers
1k views

What are the limitations of chrome headless browser?

We have written bunch of test cases for code coverage using jasmine javascript. First of all, we are using phantom JS to run the test cases. While test case counts are persistently increased test ...
8
votes
3answers
512 views

End-to-end tests are running for 5 hours

This is a continuation of Speeding up end-to-end tests topic, but a more specific one. Currently, it takes ~5 hours for our daily end-to-end testing run to complete. What can we do to improve on ...
0
votes
5answers
4k views

What tool to use for end to end testing of SPA (Single Page Application)

What testing tool to use for automating user acceptance testing ? The itself app uses react Should I use Selenium with various wait strategies, Jasmine or a different tool ?
0
votes
1answer
4k views

Protractor: How to verify text present in the table row?

TestCase: Verify the table ROW contains text. To verify text present in Table Row, i tried Using "expect.gettext().toContain(datefinal)". But ouput returns "Expected '7/18/17' to contain undefined."...
5
votes
1answer
111 views

Test Quarantine in Protractor

Follow-up to How to deal with flaky tests? One of the approaches to tackle flaky tests is to temporarily quarantine the tests - move them to a special "bucket" with other flaky tests: I offer one ...
2
votes
0answers
450 views

Unable to add/attach screenshot and test steps in Report

I am working on protractor and using "protractor-angular-screenshot-reporter" to generate the report.But i am unable to add screenshot and test steps in this report.Can any one please help me in this....
0
votes
1answer
179 views

How can I find text for span within span?

Following is my code: <span id="agText" class="ag-header-cell-text"> <span style="height: 100%;">Coordinator</span> </span> I was trying the following: var cordinator = ...
1
vote
3answers
929 views

How can I locate the navigation element by text?

<li class="nav-item" ng-reflect-ng-class="nav-item,"> <a class="nav-link" href="javascript:void(0);"> <span>By Coordinator &amp; Salesman</span> <!-...
3
votes
1answer
354 views

How can I add headings to my protractor-jasmine2-screenshot-reports

I am sharing my spec file, the generated report contains only 'through Gmail Account' text but I want to add 'Password pop up' text and many other headings also. I tried by adding one more 'it' block ...
0
votes
1answer
154 views

Jasmine web services automation “getting started” doc

I have been working on nightwatchjs from past 6 months, before that I was using Selenium-WebDriver to do browser automation. I have syntactical knowledge of JS and I assume that Jasmine won't bother ...