Why I Built IT

After learning Playwright, I saw an opportunity to build a POC that would both showcase my skills and help the team move away from the manual checks that take us a few hours. One use case that came to mind was our framework products – a multi-tenant engine that gives each client specific branding, content filters, and feature toggles from a single codebase. Clients provide a requirement doc and we build the website on top of it, and QA uses that same doc as a checklist to validate the implementation before sign-off. So I built ARGUS, a test framework that reads the requirement doc and checks the site against it.

The Problem with Our Old Tests

I noticed the automated tests we had were hardcoded to each product’s own content and UI, and weren’t adaptable to client requirement docs. A client with custom branding or content would either fail them outright or require a code change. Going through the old suite, I found a loop over a hardcoded list of 100+ client subdomains with a comment that says they don’t really belong to any long-term test cases. On top of that, we were maintaining an automated suite that still fell back to manual checks anyway, so we paid for the automation and the manual pass on the same release. We needed something robust: a requirement-agnostic framework.

The idea: let the requirement doc drive the tests

At first, I considered expanding what we already had, but then realized I’d just be cushioning the blow rather than tackling the problem. Why carry the maintenance overhead of adding or updating the test cases to match a different set of requirements, such as changes in titles and interactive tool names? That’s why I built a test framework where tests read requirements straight from Confluence, where they already live, instead of hardcoded values. It cuts the maintenance, and the only upkeep left is keeping the doc accurate as requirements change, such as custom branding, filters, navigation, or footer links.

How ARGUS Works

A requirement doc comes in a table format with a key in the first column and its expected value in the second. ARGUS reads the page through the Confluence REST API and gets the table rows. It normalizes each key and matches it to the req-test-mapping, using that mapping to select the corresponding Playwright test. For instance, a CTA text and URL becomes a check that the page’s CTA is visible, its title contains the doc’s text, and its link matches the URL. At the end, it produces a Coverage Gap Report with categories such as covered (in the doc, test exists), untested (in the doc, no test), and unmapped (in the mapping, but not requested by this client). It’s informational, so a missing test shows up as a gap, not a failed page check.

How ARGUS works

Two Features I’d Build Again

I personally love two features from this framework. One is the self-healing locators. I didn’t even know that this thing existed until I implemented it with ARGUS. It solved a problem I’d been struggling with: locators changing on every new build. The solution is a fallback strategy that tries a list of locators in order. If footer scoped getByRole doesn’t work, it falls back to a page-wide getByRole, then getByText. If every strategy fails, it logs [HEAL FAILED] and returns nothing, causing the test assertion to fail rather than passing silently. It blew my mind and it is satisfying to see that [HEALED] note in the Playwright report when a test adjusts to a fallback locator and still runs. The second feature, which I almost skipped, is the factory pattern. It’s incredibly useful when you have multiple validations sharing the same shape, like footer links. It let me cut the code roughly in half by consolidating every step and assertion in one place and just calling them in each test. Adding another test came down to about 4 lines of code plus a mapping entry.

What the team Liked

The Playwright HTML report was a big hit, especially the filters for passed, failed, flaky, and skipped tests. One click and everything else is out of the way.

Playwright HTML report

My dev manager was most excited about running it from outside the IDE. The pipeline takes three inputs: the Confluence page ID, the website URL, and a scope (all, smoke-only, or mapped-only). No more waiting on a developer to kick it off, and no pulling down the repo and configuring it just to run the tests.

Run workflow

The first red test taught me the most. On a client run, “CTA #3 text and URL match requirement doc” failed, and I assumed a defect until I opened the doc: CTA #3 was marked NA, meaning the client didn’t want a third button. The site was right and ARGUS was wrong. It treated “NA” as a value and went looking for a CTA that shouldn’t exist.

The requirement doc marks CTA

The Coverage Gap Report did its job in the same run. It ran last and flagged CTA 4 and 5 as unmapped, because that client’s doc never asked for them.

Lessons From CI

Passing locally and passing in CI turned out to be two different things. In a recent local run against the same client doc and site, 15 of 16 tests passed in 2.4 minutes, and the footer checks were green. In the pipeline, three footer checks failed: the “Powered by” logo, “About StayWell”, and the disclaimer link. The log showed the self-healing locators trying every strategy and giving up on those three, while two other footer links healed through a page-wide role locator. In another pipeline run on the same site and doc, all nine mapped tests failed. Still under investigation.

Lessons from CI

One CI run failed more dramatically. All 11 tests timed out on page.goto after 60 seconds each, about 12 minutes in total, against a non-production site. It turned out to be the site’s bot protection. The lesson: a CI timeout isn’t always a slow site, so check whether the runner is being blocked before blaming the tests. I used real Chrome in CI to avoid Cloudflare TLS fingerprinting.

What I’d do Differently

I had fun building ARGUS Playwright framework, and it achieved most of what I wanted, from reading requirements in Confluence to running mapped tests. Functionally, I’m proud of it. However, if I started over, I’d integrate the same requirement-aware logic into our existing org-wide automated testing repo, since that’s where the whole QA team already pushes and triggers tests, though I haven’t confirmed if that’s feasible yet.

One regret is that I couldn’t get QAs more enthusiastic, as pipelines kept failing for reasons outside the tests themselves. The constant issues were discouraging. That also made a handoff harder, and I moved teams before it happened. I built it for a project on my old team, so the framework is now left gathering dust.

Takeaway

If you want to build something like this, start with what’s already available to you and scale from there. Adoption comes from how visible it is, how easy it is to trigger, and how quickly people can get up to speed, so centralize everything in the one place your team already uses.

Ready to Streamline QA with Smarter Test Automation?

DEV IT helps businesses build reliable, scalable test automation solutions that reduce manual testing efforts, improve test coverage, and accelerate software delivery.

Talk to Our Test Automation Expert

FAQs

ARGUS is a requirement-driven test automation framework built using Playwright. It reads client requirements directly from Confluence and automatically selects the relevant test cases to validate a website. This reduces hardcoded test dependencies, minimizes manual QA efforts, and makes testing more adaptable to client-specific branding, content, and functionality.

ARGUS connects to Confluence through its REST API and reads requirement tables containing test keys and expected values. It matches these requirements against a predefined test mapping and executes the corresponding Playwright tests. This allows QA teams to update requirements in Confluence without manually modifying test cases for every client-specific change.

A self-healing locator is a fallback mechanism that tries alternative element selectors when the primary locator fails. In ARGUS, if a role-based locator cannot find an element, the framework tries other strategies, such as page-wide role-based or text-based locators. This helps tests handle minor UI changes without immediately failing, although it cannot fix every locator issue.

ARGUS generates a Coverage Gap Report after test execution. It categorizes requirements into three groups:
– Covered: A requirement exists in the document and has a corresponding automated test.
– Untested: A requirement exists in the document but has no mapped test.
– Unmapped: A test exists in the framework but is not requested in the client’s requirement document.
This helps QA teams identify automation gaps and understand which requirements still need test coverage.

Playwright tests may pass locally but fail in CI because of differences in browser environments, network conditions, execution speed, browser configurations, or bot protection. For example, Cloudflare may block automated CI traffic even when the website works normally in a local browser. Teams should investigate CI logs, locator failures, network access, and browser configurations before assuming the application has a defect.