Add the capability to perform testing in multiple browser windows
See original GitHub issueAre you requesting a feature or reporting a bug?
Feature
What is the current behavior?
You can run test only in single window of the browser
What is the expected behavior?
It’s useful to run test in multiple windows to simultaneously observe results from different users perspective. E.g. we test online chat or online game. The idea is to spawn new windows in test and switch test context to that window (It also we’ll play well with Roles feature):
test('Multi-window', async t => {
await t
.switchRole(user1)
.click('#start-game')
.switchToWindow(1) // Spawns new browser window if it wasn't used before
.switchRole(user2)
.click('#start-game')
.click('#shoot')
.switchToWindow(0); // Return to default window
expect(await healthbar.value).eql(0);
});
The syntax is still a subject for bikeshedding. \cc @DevExpress/testcafe
Issue Analytics
- State:
- Created 7 years ago
- Reactions:211
- Comments:94 (26 by maintainers)
Top Results From Across the Web
What is Cross Browser Testing and How to Perform It
Cross Browser Testing is a type of testing to verify if an application works across different browsers as expected and degrades gracefully.
Read more >Cross Browser Testing using Selenium WebDriver - Guru99
Cross Browser Testing is a type of functional test to check that your web application works as expected in different browsers.
Read more >Cross Browser Testing in Selenium : Tutorial | BrowserStack
Learn how to get started with cross browser testing using Selenium with examples. Read about best practices to follow for multi browser ......
Read more >Introduction to cross-browser testing - Learn web development
Cross -browser testing is the practice of ensuring that a website works across various browsers and devices. Web developers should consider:.
Read more >Cross Browser Testing in Selenium [Tutorial] - LambdaTest
Browser coverage is an integral aspect of test coverage. The primary agenda of cross browser testing is to perform testing on different browsers...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi guys,
We are ready to introduce the
testcafe@1.8.5-alpha.1
version with the basic support of testing in multiple browser windows.The ‘basic support’ means that TestCafe will open a new browser window and close it in the same way as a web browser. This functionality covers the ‘Login via something’ scenario. To switch to another browser window, you don’t need to execute any additional actions - TestCafe does this automatically. See the ‘Login via Google’ example:
‘Testing in multiple browser windows’ is an experimental option. To use it, you need to add the necessary command line or programmatic option.
At present, not all the problems related to the ‘Testing in multiple browser windows’ feature are fixed (for example, Login via Facebook is too slow). We continue working on bug fixes and stability improvements and will release a new TestCafe version with necessary fixes as soon as possible.
Guys, try to write tests that require the multiple browser window support and run them with the
testcafe@1.8.5-alpha.1
version. Please share your experience with us. Also, we really want to know what functionality you require besides the basic support of testing in multiple windows.If you face any issues or have any suggestions, please create separate issues with the
window management
tag.Folks
We are happy to announce that we released the mentioned feature (‘Add the capability to perform testing in multiple browser windows’) in
testcafe@1.11.0
. See the documentation in the following help topic: https://devexpress.github.io/testcafe/documentation/guides/advanced-guides/multiple-browser-windows.html.