testling | unit tests in all the browsers | Unit Testing library
kandi X-RAY | testling Summary
kandi X-RAY | testling Summary
unit tests in all the browsers
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of testling
testling Key Features
testling Examples and Code Snippets
Community Discussions
Trending Discussions on testling
QUESTION
I'm trying to set up automated frontend testings with browserstack, selenium-webdriver and tape.
The idea is to define multiple browsers and devices which have to be tested one after another with X amount of given tests. In the example below I define only one test and two browsers on OSX.
In order to define the browsers only once and handle tests I created a repo test-runner
which should be added as dev-dependency
to the repos which need to be tested on the given devices and browsers.
The test-runner
gets all needed tests passed, starts the first browser, runs the tests on that browser and once all tests are done the browser is closed quit()
and the next browser gets started and tests again.
test-runner
/index.js
...ANSWER
Answered 2018-Nov-12 at 09:49It seems like tape
does not work so well with asynchronous code. See these discussions on their Github issues page:
https://github.com/substack/tape/issues/223
https://github.com/substack/tape/issues/160
The solutions seems to be to declare your tests with tape.add
in the beginning, before any async code gets called.
I would also try to refactor some of that async code that might not be needed, if you're just opening browsers in a sequence.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install testling
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page