Software Development
Test Automation with Selenium and Playwright
Automation suites earn their cost only when they run fast and fail honestly. This course builds maintainable Selenium and Playwright suites: locator strategies that survive UI changes, page objects with clear boundaries, deterministic waiting, parallel cross-browser execution, and a sound API-versus-UI split.
Overview
Practical learning for workplace transfer.
Most automation projects die the same way: the suite grows, run time climbs past what anyone will wait for, and enough tests fail intermittently that the team stops reading the results. This course targets that decline directly. Participants build suites in both Selenium and Playwright, compare their execution models, replace sleep-based waiting with deterministic conditions, isolate test data so runs do not interfere with each other, and push the suite into a pipeline where it must finish inside a defined time budget and report failures a developer can act on without rerunning anything.
Prerequisites
Basic programming ability in JavaScript, TypeScript, Python, or Java, and practical experience testing a web application manually.
Objectives
- Build Selenium and Playwright suites against the same application and compare the results.
- Write locators that survive markup changes and express user-visible intent.
- Eliminate flakiness through deterministic waiting, test isolation, and controlled data.
- Structure suites with page objects and fixtures that stay readable as coverage grows.
- Execute tests in parallel across browsers within a defined pipeline time budget.
- Decide which checks belong at API level and which genuinely require the interface.
Target audience
- QA engineers moving from manual testing to automation
- Test automation engineers and SDETs maintaining existing suites
- Developers who write end-to-end tests for their own features
- QA leads defining automation strategy and coverage targets
- Release engineers integrating test suites into delivery pipelines
- Teams replacing an unreliable legacy automation framework
Program outline
A clear structure for the learning journey.
Program outline
Outline points are grouped in one designed block instead of being treated as separate module cards.
Module 1: Automation Strategy and Tool Selection
What to automate, what to leave manual, and what to test below the interface
Selenium WebDriver and Playwright architectures compared in practice
Test pyramid decisions driven by feedback speed and defect cost
Setting coverage, run-time, and reliability targets the team will defend
Module 2: Locators, Selectors, and Resilient Element Access
Selector strategies ranked by stability: roles, test ids, text, and CSS
Why long XPath chains break and what to use instead
Working with shadow DOM, iframes, and dynamically rendered components
Agreeing test-id conventions with the development team
Module 3: Waiting, Synchronization, and Flakiness Control
Implicit, explicit, and auto-waiting compared across both tools
Diagnosing a flaky test from traces, screenshots, and recorded video
Test data isolation, seeding, and cleanup between runs
Handling animations, network latency, and third-party widgets
Module 4: Suite Architecture and Maintainability
Page objects, component objects, and where the pattern breaks down
Fixtures, hooks, and shared setup without hidden dependencies
Assertions that describe business outcomes rather than DOM state
Keeping configuration, environments, and credentials out of test code
Module 5: Parallel, Cross-Browser, and API-Assisted Testing
Parallel execution, sharding, and worker isolation
Cross-browser and responsive coverage without duplicating tests
Using API calls for setup, teardown, and state verification
Network interception, mocking, and testing error states deliberately
Module 6: Continuous Integration and Reporting
Running suites in containers with reproducible browser versions
Artifacts that make a pipeline failure diagnosable: traces, logs, and video
Quarantine, retry, and the policy for a persistently failing test
Reporting coverage and stability trends to delivery stakeholders
Materials provided
- Course workbook, annotated code samples, and reference notes
- Hands-on lab environment and starter repositories
- Exercises, checklists, and reusable code templates
- 4D Certificate of Completion
- Post-course technical guidance
Training Options
Programs can be delivered in-house, online, or in a blended format depending on your team's schedule, location, and learning objectives. When an external certificate or exam is included, certification rules and fees remain under the relevant awarding body's policies, while 4D provides the training and preparation support.
Why choose 4D
4D builds this course around your application under test, not a demo storefront. Trainers audit the existing suite, rewrite its least reliable tests in both tools, and leave the team with a measured flakiness rate, a test-id convention agreed with the developers, and a suite that fits inside the pipeline budget you set.
Related courses
Python Programming Fundamentals
A hands-on introduction to Python for engineers and analysts who need working code rather than tutorial fragments. Participants build fluency with data types, collections, functions, files, and error handling, then assemble a small program that reads real data and produces a usable report.
View courseIntermediate Python and Clean Code Practices
Designed for developers whose Python works but is difficult to change. The course covers dataclasses, generators, decorators, context managers, and type hints, then applies the refactoring moves that turn a nine-hundred-line module into small tested units guarded by black, ruff, and mypy.
View coursePython Automation and Scripting for Work Tasks
Aimed at teams losing hours every week to repetitive file, spreadsheet, and reporting work. Participants automate those tasks with Python: batch file handling, Excel and CSV processing, REST API calls, email alerts, and scheduled jobs that run unattended and report clearly when something fails.
View course