Resources - Ahsanmumtaz1105/cypress-end-to-end-test-demo GitHub Wiki

NextGen End-to-End Web Test Automation

Cypress

07 January 2021

Resources

Dashboard Service Demo Url

https://dashboard.cypress.io/projects/7s5okt/runs/2630/overview

CI Integration examples

https://docs.cypress.io/guides/guides/continuous-integration.html#Examples

Cypress Command APIs

https://docs.cypress.io/api/api/table-of-contents.html

Assertion APIs

https://docs.cypress.io/guides/references/assertions.html#Chai-jQuery

Plugins Types

https://docs.cypress.io/plugins/index.html

Cypress Xpath Plugin package

https://www.npmjs.com/package/cypress-xpath

Cypress Examples/Blog/Recipes repos

https://docs.cypress.io/examples/examples/recipes.html#Fundamentals

Working with iframes in Cypress

https://www.cypress.io/blog/2020/02/12/working-with-iframes-in-cypress/
Working Example: https://github.com/cypress-io/cypress-example-recipes/tree/master/examples/blogs__iframes
community package: https://www.npmjs.com/package/cypress-iframe

CSS Selector - Chrome Extension

https://chrome.google.com/webstore/detail/css-selector-helper-for-c/gddgceinofapfodcekopkjjelkbjodin?hl=en


Selectors Xpath or CSS?

The use of XPath is generally discouraged for several reasons: it turns out to be a complicated method to use; also there’s no need to use them by development teams, so developers won’t be aware of actions that change XPath location of elements, but these actions will difficult a lot the tests that are using this method; furthermore XPath is implemented differently amongst browsers, so you’ll have to be aware of those differences when using it. However, the use of XPath can be recommended in specific cases, for instance when needing to locate a parent element of the one we can track down, XPath can offer this feature easier than other methods available.

Simon defends that CSS locators are preferable for many reasons, for instance they are shared with Design and UX teams, so there are more people aware of them and they won’t change that easily. This makes tests based in CSS locators more maintainable than the ones based in unknown locators beyond test teams like XPath. Another plus of using CSS locators is that they are less brittle, being able to survive general DOM re-buildings.

https://conference.eurostarsoftwaretesting.com/liveblogged-automated-web-testing-traps-unwary-simon-stewart

⚠️ **GitHub.com Fallback** ⚠️