Locator Strategies with Playwright
Playwright is a robust test automation framework that enables reliable end-to-end testing for modern web applications. It supports multiple languages, is super simple to get started, and is super fast in running tests.
Playwright uses Locators to find elements on a page. Because they are essential to some of Playwright’s most powerful features—auto-waiting and retry-ability—multiple locators are built into Playwright. But, how do you choose the best locators to use to maximize stability and add the most value to your tests?
In this session, Renata Andrade plays with different locators for common scenarios. She evaluates the simplicity, stability, speed, and actionability checks of each while she demonstrates the importance of using a good locator strategy.
Along the way, you will see Playwright’s Test Generator, Trace Viewer, and the UI Mode help with locator creation and the auto-waiting functionality. Renata will also explore the impact of your locator strategy on Visual Regression Tests with Applitools.
If you’re considering changing your test automation framework to Playwright or if you’re just not sure you’re using locators correctly, you don’t want to miss this session.
Key takeaways:
- Understand the difference between the different built-in locators in Playwright
- Learn how to decrease flakiness on your tests
- Learn how to speed up your tests by using a good locator strategy
- Learn how to use the Test Generator, the Trace Viewer, and the UI Mode to help you with locator creation
- Understand the impact of locator strategy on Visual Regression Tests with Applitools
Playwright is a robust test automation framework that enables reliable end-to-end testing for modern web applications. It supports multiple languages, is super simple to get started, and is super fast in running tests.
Playwright uses Locators to find elements on a page. Because they are essential to some of Playwright’s most powerful features—auto-waiting and retry-ability—multiple locators are built into Playwright. But, how do you choose the best locators to use to maximize stability and add the most value to your tests?
In this talk, Renata Andrade plays with different locators for common scenarios. She evaluates the simplicity, stability, speed, and actionability checks of each while she demonstrates the importance of using a good locator strategy.
Along the way, you will see Playwright’s Test Generator, Trace Viewer, and the UI Mode help with locator creation and the auto-waiting functionality. Renata will also explore the impact of the locator’s strategy on your Visual Regression Tests with Applitools.
If you’re considering changing your test automation framework or you’re just not sure you’re using locators correctly, you won’t want to miss this session.
Key takeaways:
- Understand the difference between the different built-in locators in Playwright
- Learn how to decrease flakiness on your tests
- Learn how to speed up your tests by using a good locator strategy
- Learn how to use the Test Generator, the Trace Viewer, and the UI Mode to help you with locator creation
- Understand the impact of locator strategy on Visual Regression Tests with Applitools
Applitools is the world’s most intelligent test automation platform. See it in action with a personalized demo.
Expert Speakers
![](jpg/renata-andrade-e1690555662719.jpg)
Test Automation Engineer & Architect
Renata Andrade is a Software Quality champion. She helps teams build the best strategy to practice quality in the easiest, fastest, and most reliable way possible, adding more value to the business. She likes working in a high tech environment with difficult challenges to solve. Driven by excellence, innovation, and creativity, Renata loves making a difference, learning, sharing knowledge, and inspiring people through mentoring, lectures, and trainings in Portuguese and English.