Testing in 2026
Recently, I had to run regression tests to keep a complex process running while I made changes and added features.
Regression testing helps ensure quality and build client trust when we run large/complex processes; it is crucial to make sure old features keep working as expected and to catch any overlap early.
I know this is common in our sector, and we don't want to break anything that is already done, so being meticulous is a must. As engineers, we try to make things as simple as possible for the next time we walk through the same path, so.. I found my dream team to accomplish this goal:
If this is your first time taking testing to the next level like me, welcome!
Playwright is an end-to-end test framework for modern web apps. It bundles a test runner; here are some of the most-used commands.
Install Playwright: npm i -D playwright
Generate code through the steps you do in the browser: npx playwright codegen [url]
Run your testing: node .\hello-playwright.js
Some useful lines of code
Get a screenshot of the result:await page.screenshot({path: `UserStoryResult.png`});Record Playwright Testing:
const context = await browser.newContext({
recordVideo: {
// where is going to be saved
dir: `videos`
}
});
We're in the AI era, so I found that Playwright has an MCP that makes this easier. You can install it from Visual Studio Code.
First, create your repository in Azure DevOps.
Save and Run your Pipeline. You will find this tab with the test results.
Another challenge was authentication because of MFA, so I used a service account. I can write more about this in another post.
References
What is Playwright? (🎭 Playwright introduction tutorial, features & demo)
Why Do You Need (or NOT) the Playwright MCP Server?
#3 Playwright with Azure DevOps Pipeline Tutorial: Complete Guide
Comments
Post a Comment