Skip to content

Test quality defect patterns

This page lists defects in ConnectSoft tests themselves. A defective test either passes while the product is broken, or fails while the product works. Each pattern names the symptom you see, the cause, what to look for in a review, and how to prove the test is sound. The rules these patterns break are on the testing standard, test data and databases, BDD with Reqnroll, end-to-end tests with Playwright and architecture tests.

The strongest single check for any new test is to break the behaviour it covers, or revert the fix it protects, and watch the test fail.

Tests that cannot fail

CS-DP-TST-001: Test that cannot fail

Severity: major · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

The tests pass while the feature is broken end to end.

Cause

  • The test double can never succeed, for example a stub that names nobody.
  • The fixture lacks the data, so two empty collections compare equal.
  • The data set is smaller than the edge case, for example fewer rows than a row shift.
  • The assertion is true of any output, for example that an exported file starts with PK.

Check

For each double, fixture and assertion, ask whether the test could go red if the behaviour were removed.

Test

Remove the call or revert the fix, and confirm that the test fails.

CS-TST-020, CS-E2E-007

CS-DP-TST-002: Test setup cannot tell the broken behaviour from the fixed one

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

Scope or fallback tests pass against the old, broken behaviour.

Cause

  • The tests run as an administrator, who bypasses the filter.
  • All seed data sits in the one unit that every persona holds.
  • A sign-in while already signed in keeps the previous session.
  • The test host's time zone equals the product default under test.

Check

For each persona and environment choice, ask whether the expected value differs between correct and incorrect code.

Test

  • Use a non-administrator persona whose scoped and unscoped answers differ.
  • Use a configured time zone that differs from the host's.
  • Sign out and check the identity before each persona switch.

CS-E2E-007, CS-TST-028

CS-DP-TST-003: Withholding assertion passes because the selector never matched

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

Scenarios of the form "the user does not see X" stay green while measuring nothing.

Cause

Attribute selectors match case-sensitively, and the same identifier is cased differently on each side of the wire, for example a PascalCase enum name against a camelCase wire name. A count-is-zero assertion then passes whether the rule works or the selector is wrong.

Check

  • A refusal or absence assertion with no matching positive control.
  • An attribute selector built from a server enum name instead of the UI's own constant.

Test

Pair every refusal with a scenario in which the same content is visible to a user who may see it, and use the case-insensitive i flag on identifier attribute selectors.

CS-E2E-007, CS-TST-020

CS-DP-TST-004: Status-only assertion satisfied by a different guard

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A refusal scenario passes, yet removing the guard under test does not make it fail.

Cause

Several guards on the same path return the same status, for example 409, and the assertion checks only the status and a title.

Check

Refusal tests that assert only the status code when other guards on the same path produce it.

Test

Assert something that only the guard under test produces, such as its error code, and prove it by disabling that guard.

CS-VAL-005, CS-E2E-007

CS-DP-TST-005: End-state assertion misses a compensated write

Severity: major · Applies to: service, library, template · Enforced by: manual · Status: active

Symptom

Removing a "validate before storing" guard leaves every test green.

Cause

The test asserts that nothing is left at the end, but the write happened and a compensating delete removed it.

Check

"Nothing stored" assertions over end-state collections, for paths that have compensation.

Test

Assert a write counter that only increases, and remove the guard to confirm that the test goes red.

CS-TST-021

CS-DP-TST-006: Assertion over an empty filtered subset

Severity: major · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

A test passes in exactly the failure it was written to catch.

Cause

All(...) over an empty sequence is true, and a foreach assertion runs zero times. A filtered subset is often empty precisely when the behaviour is wrong.

Check

.All( or loop-only assertions over a Where(...) result, without a count or non-empty assertion before them in the same test.

Test

Assert the subset's expected count before asserting over its members.

CS-TST-020

CS-DP-TST-007: Seed test counts rows by a referenced id

Severity: minor · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A seed test fails with "expected 10, actual 0" although the seed ran, and its negative twin passes without testing anything.

Cause

The test counts seeded rows by a referenced id, such as the owner or the creator, which a later change replaced, instead of by the seed's own identifiers.

Check

Seed tests that filter on foreign or owner ids rather than on the ids the migration's Down() deletes by.

Test

The same count query returns the expected number with the seed applied and zero without it.

CS-TST-022, CS-TST-020

CS-DP-TST-008: Guard checks an incomplete or empty subject set

Severity: blocker · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

Architecture rules or artifact validators pass while the code breaks them.

Cause

The rules scan AppDomain.GetAssemblies() or Types.InCurrentDomain(), which return only the assemblies already loaded, or a validator points at a guessed root folder that contains nothing.

Check

Guards that find their subjects implicitly, with no assertion on the size or the identity of the scanned set.

Test

Assert that the scanned set equals the shipped set, for example the assemblies next to the test assembly, and that each rule matched at least one type.

CS-TST-025, CS-TST-026

CS-DP-TST-009: Static guard whose pattern matches nothing always passes

Severity: major · Applies to: service, library, api-client, blazor, template, docs, pipelines · Enforced by: manual · Status: active

Symptom

A pipeline or repository check reports success while the defect it guards exists, and the number of items it reports is lower than the real number.

Cause

The guard's regular expression never matches, for example because of escaped backslashes in a double-quoted string, or a \w that misses namespace-qualified names. The check then runs over an empty or partial set.

Check

Guard scripts without an assertion on how many items they examined. Compare that count with an independent search.

Test

Break one item on purpose and confirm that the guard fails, then restore the item and confirm that the guard passes again.

CS-TST-026, CS-TST-010

Runs, filters and environment

CS-DP-TST-010: Stale test assembly reports green

Severity: major · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

A run reports that all tests passed, but the new tests were never in it.

Cause

The test project failed to compile, the previous assembly stayed in the output folder, and a run with --no-build executed it.

Check

--no-build runs after edits.

Test

Run the new test class's filter alone, after a build, and assert that the number of tests run is not zero.

CS-TST-010

CS-DP-TST-011: Zero-match test filter reports a green run

Severity: major · Applies to: service, library, api-client, blazor, template, pipelines · Enforced by: manual · Status: active

Symptom

A filtered dotnet test prints "Passed!" while one whole test assembly ran no tests.

Cause

A --filter on a category that the assembly's tests do not carry matches nothing, and a runsettings file with TreatNoTestsAsError=false turns that into exit code 0. The zero-match line scrolls past above another assembly's pass summary.

Check

  • A runsettings file that sets TreatNoTestsAsError to false.
  • A pipeline or test command that filters by a TestCategory the target projects do not use.

Test

A pipeline check fails when any test assembly reports Total: 0 or "No test matches".

CS-TST-010, CS-TST-004, CS-TST-015

CS-DP-TST-012: Unanchored step pattern read as a Cucumber expression skips the scenario

Severity: blocker · Applies to: service, template · Enforced by: manual · Status: active

Symptom

dotnet test exits with code 0, the scenarios are reported as skipped, and their assertions never run.

Cause

A step pattern with (a|b) but without anchors is read as a Cucumber expression and binds nothing. The default outcome of a missing step is Inconclusive, which is reported as skipped.

Check

Step attributes with regular-expression syntax but no ^…$ anchors.

Test

  • A test-run configuration that fails on undefined steps.
  • A check that the skipped count is zero when no scenario is tagged to be ignored.

CS-TST-011, CS-TST-009

CS-DP-TST-013: And step inherits a keyword its binding does not have

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A step whose text matches a binding exactly is reported as undefined, and every later step is skipped.

Cause

And and But take the keyword of the step above, so an And after a Given is a Given, and a binding declared only with [Then] is not consulted.

Check

Steps copied between scenarios where the preceding keyword differs from the binding attribute.

Test

A run that fails on undefined steps. Write the explicit keyword that the binding uses.

CS-TST-013, CS-TST-009

CS-DP-TST-014: Optional capture group fails with a parameter count mismatch

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A step binding fails at run time with "Parameter count mismatch" when the sentence leaves out an optional clause, while the full form passes.

Cause

The step framework passes no argument for an optional capture group that did not match.

Check

Optional groups that contain captures, such as (?: through (.*))?, in step patterns.

Test

One scenario per sentence form. Prefer one binding per form.

CS-TST-012

CS-DP-TST-015: Change verified by a partial test run leaves stale assertions elsewhere

Severity: major · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

CI goes red on an acceptance test or a consumer repository's test after a change that was green locally.

Cause

A reversed rule or a reworded message is pinned by tests in other test projects or repositories, and only a filtered subset or the owning service's unit tests were run.

Check

A change of behaviour or wording whose description lists only one test project. Search for the old terms and literals across every test project and repository, XML comments included.

Test

Run the full suites of every repository the change touches, and assert message constants rather than literal text.

CS-DOD-002, CS-TST-010, CS-DOD-008

CS-DP-TST-016: Two coverage collectors skew the quality gate

Severity: major · Applies to: service, library, api-client, blazor, template, pipelines · Enforced by: manual · Status: active

Symptom

The pipeline gate reports much lower coverage, over a different line count, than the Coverlet report.

Cause

The runsettings file enables both the Microsoft code coverage collector and Coverlet. The gate reads the Microsoft data, which counts lines differently and includes the test assemblies.

Check

friendlyName="Code Coverage" enabled in a runsettings file next to Coverlet.

Test

A pipeline check that the gate's line count matches the published Cobertura report.

CS-TST-008, CS-DOD-003

CS-DP-TST-017: Test finds the repository root by walking up from its binary

Severity: minor · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

Dozens of unrelated tests fail with "could not locate the repository root" when the build output is redirected.

Cause

The tests walk up from AppContext.BaseDirectory, which is outside the repository when --artifacts-path or another output folder is used.

Check

Tests that locate repository files relative to the binary folder.

Test

Anchor on [CallerFilePath], and run the suite once with an output path outside the repository.

CS-TST-007, CS-TST-031

Test data and databases

CS-DP-TST-018: Test fixture destroys a database it does not own

Severity: blocker · Applies to: service, template · Enforced by: manual · Status: active

Symptom

  • Running an acceptance suite locally empties the development database.
  • CI shows random 404 and 424 responses when another assembly's fixture deletes rows in the middle of a scenario.

Cause

  • Start-up drops a database by a constant name, whatever the connection-string override says.
  • A fixture clears whole tables of a shared database while test assemblies run in parallel processes.

Check

Drops and deletes in fixtures target a database that is derived from the fixture's own connection string and unique to the suite.

Test

A guard test asserts that the fixture's database name differs from the runtime name and is specific to the suite.

CS-TST-016, CS-TST-017, CS-PER-005

CS-DP-TST-019: Test fixture writes to the runtime database

Severity: blocker · Applies to: service, template · Enforced by: manual · Status: active

Symptom

  • After a green test run, a running service has empty or polluted tables.
  • Scenarios fail only locally, because earlier use left data behind.

Cause

  • Unit-test or acceptance settings ship the runtime connection string, and fixtures such as a mapping-verification helper commit their rows.
  • A fixture resolves the runtime connection string without overriding the catalog, or its drop target names the runtime database, and then migrates down, deletes or drops.
  • CI passes because it always gets a fresh container.

Check

  • Test settings or fixtures whose database name equals the runtime one.
  • Fixtures that call MigrateDown, DELETE FROM, TRUNCATE or a drop without an explicit test catalog. Check both the connection string and the drop target.
  • Fixtures that rewrite the catalog in only some of the services.

Test

Set the catalog in code to a suite-specific database, and assert that the row counts of the runtime database are identical before and after the suite.

CS-TST-016, CS-TST-017, CS-PER-005

CS-DP-TST-020: Stale pooled connections after a test database drop

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

Random login failures (SQL error 18456) or "Invalid object name" errors in CI after a database is dropped and recreated for each feature. The suite passes locally.

Cause

The connection pool lives for the whole process, keyed by connection string, so it outlives the per-feature host and hands out connections bound to the dropped database.

Check

Drop-database helpers without SqlConnection.ClearAllPools() and a bounded retry after the drop.

Test

Two features in one process each drop and recreate the database, and the test asserts that the second feature's first query succeeds.

CS-TST-018

CS-DP-TST-021: Migrate-down test counts tables another suite's host created

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A migrate-up-and-down test fails only when another test suite ran first.

Cause

The test asserts an exact table count after migrating to zero, while a host started by another suite creates infrastructure tables, such as the outbox or the transport tables, in the same database.

Check

Migration tests that count all tables in a database shared with any suite that starts the real host.

Test

Run the migration test against its own database, or exclude the runtime infrastructure schemas explicitly.

CS-TST-016, CS-TST-017

CS-DP-TST-022: Mapping test pins a fixed value on a unique column

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A persistence-mapping test passes on its first run and fails with a unique-constraint violation on every later run against the same database.

Cause

The mapping-verification helper commits the row it inserts, so a fixed value on a column mapped as unique collides with the row left by the previous run.

Check

A CheckProperty call, or any committed insert, that sets a literal on a unique column, such as Order.Number = "ORD-1" or a fixed unique date.

Test

Run the mapping suite twice in a row against the same database. Both runs must pass.

CS-TST-007, CS-TST-019, CS-PER-009

CS-DP-TST-023: Created row is looked for on the first page of a growing list

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

Scenarios that create a row and look for it start failing together after a shared test environment grows, pass when run alone, and fail again about one run in three. The failure reads as "the save was lost", while the row sits on page 2.

Cause

The shared database is never reset. Fixtures create rows on every run, or keep adding children to one fixed record, and the default sort puts new rows last or past the page cap. The assertion looks at the first page only, so waiting longer never helps.

Check

  • An assertion that a created row is listed, without paging, filtering or searching to it.
  • Fixtures that seed on every run instead of only the shortfall.

Test

Filter by an identifier the scenario owns, or walk the pages to the row, and word the failure as "created and on none of the pages".

CS-TST-023, CS-TST-019

CS-DP-TST-024: Fixture locates its subject by a non-unique attribute

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

A scenario passes on a fresh database and then fails on every later run with a correct uniqueness refusal (409).

Cause

A find-or-create fixture searches by a shared name and takes the first row, while the following steps send a fixed unique id. Once a namesake exists, the write targets the wrong record and the server rightly refuses it.

Check

  • FirstOrDefault() over a search by name, in a fixture whose later steps use a fixed id.
  • Exact matches on keys that the system stores normalised, for example with leading zeros.

Test

Filter the search results by the identifier that the later steps assert on, with a normalised comparison and a page size above the number of namesakes.

CS-TST-019, CS-TST-007

CS-DP-TST-025: Scenario consumes a finite seeded pool and never returns it

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

A scenario that was green for weeks fails for lack of test data, which reads like a product defect.

Cause

Each run permanently consumes seeded records, for example accounts created from a pool that has no delete path, and a pool count made with a join that does not normalise the key reports the pool as healthy.

Check

  • A scenario that creates or converts seeded records with no cleanup hook.
  • Any count or delete keyed on an identifier that the application normalises.

Test

Measure the pool before and after a full run and require it to be unchanged, and give the scenario a cleanup hook.

CS-TST-019

CS-DP-TST-026: Capture-and-restore hook writes back "not found" as "empty"

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

A scenario passes, and a later run in a different assembly fails on missing seed data that no test deletes.

Cause

A lookup helper returns an empty list when the key is absent. The capture step reads the wrong key, and the restore hook writes the empty result back, which the API accepts as "clear all".

Check

Helpers that return an empty value for a missing key, used by any hook that writes its captured value back.

Test

Assert that the captured value was found and is not empty before the restore, and that the restored state equals the captured state.

CS-TST-014, CS-TST-030

CS-DP-TST-027: Process-wide environment state leaks between tests

Severity: major · Applies to: service, library, api-client, blazor, template · Enforced by: manual · Status: active

Symptom

A new scenario passes alone and fails in the full suite, or tests that touch one environment variable fail at random in parallel runs.

Cause

A hook sets an environment variable or a static field for a tagged feature and never restores it, or parallel test classes share a process-wide variable.

Check

Hooks or tests that call Environment.SetEnvironmentVariable or change static fields, without a matching restore and without [DoNotParallelize].

Test

Run the full suite in the default order. A leak shows as later features running with the wrong settings.

CS-TST-014, CS-TST-007

Timing, readiness and waits

CS-DP-TST-028: Test proceeds on "started" instead of "ready"

Severity: major · Applies to: service, template · Enforced by: manual · Status: active

Symptom

A feature's first step fails with "Invalid object name" for an outbox table, or the first database connection fails, only on slow CI agents.

Cause

The host's Start() returns before a background service creates its schema, or a service container is reported as started before it accepts connections.

Check

Test hooks that use resources created asynchronously after Start(), or containers used without a readiness wait.

Test

Before the first step, poll for the specific object or for a successful connection, with a bounded timeout.

CS-TST-007, CS-E2E-002, CS-TST-029

CS-DP-TST-029: Bounded waits sized from one passing run

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

Several scenarios fail at random, only under full-suite load, and pass when run alone.

Cause

The timeouts were set to whatever passed once, for example a 15-second bound on a 14-second render, so the load decides the result. Raising a bound that guards a call to another service can also hide the defect it was placed to catch.

Check

New or raised wait bounds without a measured render or call time behind them.

Test

Size each bound from measured timings with a stated margin, and rerun a single failure in isolation before reading it as a product failure.

CS-TST-007

CS-DP-TST-030: Step reads a cross-service projection before the event is consumed

Severity: major · Applies to: service, blazor, template · Enforced by: manual · Status: active

Symptom

A scenario is always green in development and fails on its first run in a test environment.

Cause

Creating a record provisions a dependent record in another service through an asynchronous event, and the page reads the dependent record once on load without refreshing.

Check

A step that creates a record and at once opens a page that shows data another service derives from it.

Test

Before opening the page, poll the other service's API for the derived record, with a bounded timeout.

CS-TST-007, CS-TST-029

CS-DP-TST-031: End-to-end wait is satisfied before the server write lands

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A UI scenario passes alone but fails in the full suite with "row never appeared", or a "nothing changed" assertion passes even when the save never reached the server.

Cause

The step waits on something the browser did to itself, such as the control's own value, a checked box, the absence of an error, or the absence of a loading indicator that has not started yet. It then navigates away or reads again, and the navigation cancels the save in flight, or the new page's single fetch runs before the commit.

Check

A step that performs a write and then asserts only the control's own state, or waits for a loading indicator to be absent, before it navigates or opens a fresh view.

Test

Settle on the server's record, read through its API, or on a server-rendered marker that carries a value unique to this write, and then assert what the page shows.

CS-E2E-008, CS-TST-007

CS-DP-TST-032: Wait for an element that is already on screen is not a wait

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A step that should wait for a run completes in milliseconds, and later steps race the run's own reload.

Cause

The step waits for a summary, a row or a loading indicator to be visible, but the previous result is still displayed, so the condition holds before the work finishes.

Check

Waits keyed on the presence of an element rather than on a value that the awaited work is certain to change, such as a run version or a page index.

Test

Assert on a changed version or index. A step duration that jumps after the fix confirms that the old wait never waited.

CS-E2E-008, CS-E2E-004

CS-DP-TST-033: Count read before the data arrives

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A screenshot shows a count of zero, and a defect is filed against the scope filter although the server returned rows.

Cause

The count renders before the rows, and the page walk skips settling on the first page.

Check

End-to-end reads of counts or totals without waiting for the server's response or a data-ready marker.

Test

Settle on every page, the first one included, on evidence the server produced, and cross-check with the server's log of the rows it returned.

CS-E2E-008, CS-E2E-004

CS-DP-TST-034: bUnit disposal is not deterministic

Severity: minor · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A test that a late reply after the page is gone does nothing fails at random.

Cause

DisposeComponentsAsync removes the component from the render tree before the component's Dispose has run.

Check

Tests that rely on side effects of DisposeComponentsAsync.

Test

Capture the component instance and call await cut.InvokeAsync(instance.Dispose). Run a new asynchronous test class about ten times before trusting it.

CS-TST-007

Browser automation

CS-DP-TST-035: Click on a prerendered control is silently discarded

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

Under full-suite load a menu never opens, a pager never moves or an option cannot be clicked. The step passes alone, and the backend log shows no request.

Cause

Prerendered markup is visible and enabled before the circuit connects and before the component's first data load. A defined window.Blazor does not mean hydration has finished, and a retried toggle closes what it just opened.

Check

  • End-to-end steps that click after navigation without waiting for the page's own circuit and data.
  • Paired steps that were hardened on one side only.

Test

Wait for the page's own connection and for the hydration markers to clear, then click in a bounded loop until the observed state changes.

CS-E2E-003, CS-E2E-005, CS-UI-004

CS-DP-TST-036: Navigation before the circuit connects raises a teardown error

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A scenario whose steps all passed fails in teardown with a negotiation or connection-closed page error.

Cause

A step navigates away while the circuit is still negotiating. A response wait matched by URL alone matches an earlier page's negotiation and proves nothing.

Check

  • Page-error filters that swallow negotiation failures.
  • Response waits that are not scoped to the frame's URL.
  • Waits armed after the click that navigates.

Test

Filter out only the two connection-closed messages, and arm a frame-scoped negotiation wait before the click that navigates.

CS-E2E-003, CS-E2E-008

CS-DP-TST-037: Pager walk races the re-render

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A page-walking step times out on a disabled "next" button, or concludes that a row is absent while it sits on a page that was skipped.

Cause

Checking IsEnabled and then clicking happen at two moments, and an interactive re-render can disable the button in between. Clicking "next" and counting at once counts the page that was already shown, so the walk skips a page.

Check

A pager loop that counts rows right after the click, or that guards a click with an enabled check without bounding the click.

Test

Walk the pages against a server-rendered page index and total, bound each click and treat its timeout as the last page, then read the list again for the final assertion.

CS-TST-023, CS-E2E-005

CS-DP-TST-038: Click retried on a menu that a re-render tore down

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

"Element is not stable", "element was detached" or a bare timeout on a locator that plainly resolved. A longer timeout changes nothing.

Cause

A late state change, such as authentication or locale hydration, re-renders the component and closes or replaces the menu. Retrying the same locator waits for something that is not coming back, and a menu that opened before its data arrived is visible but empty.

Check

End-to-end steps that wait for a menu to be visible but not populated, retry an option click without opening the menu again, or skip the click because the option is already checked.

Test

A scenario that switches the selection immediately after sign-in, with a step that waits for rendering to settle, opens the menu again on each attempt and asserts that the option list is not empty.

CS-E2E-003, CS-E2E-005, CS-E2E-008

CS-DP-TST-039: Retry loop catches the wrong exception type and never retries

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A test step fails with Playwright's own timeout message after one attempt, never with the loop's exhaustion message.

Cause

A locator action timeout is thrown as System.TimeoutException, which does not derive from PlaywrightException, so catch (PlaywrightException) around an action never runs.

Check

catch (PlaywrightException) around ClickAsync, FillAsync or WaitForAsync. Assertions are not affected. Expect catch (Exception ex) when (ex is TimeoutException or PlaywrightException).

Test

Force the first attempt to time out, and assert that the step retries and, when the attempts run out, throws its own descriptive message.

CS-E2E-006

CS-DP-TST-040: Locator resolves to the hidden responsive twin

Severity: minor · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

An end-to-end step times out with "element is not visible" on a control that exists, or a walk guarded by visibility exits early without failing.

Cause

The same test id exists in both responsive branches, or the control is hidden by CSS at this width, and .First picks the hidden one.

Check

  • Locators for responsive controls without a scope that keeps only visible elements.
  • Steps that close or act through a control hidden at phone width.

Test

Run the scenario at desktop and phone widths, with locators scoped to visible elements.

CS-A11Y-014, CS-A11Y-015, CS-E2E-004

CS-DP-TST-041: Test chooses a candidate the picker does not offer

Severity: major · Applies to: blazor, template · Enforced by: manual · Status: active

Symptom

A UI scenario fails to select an option ("did not find some options"), although the product's list is correct.

Cause

The test computes its own idea of an eligible value through a separate API query, which drifts from the picker's filter. A newly created item is also visible to a direct query before the asynchronous projection that feeds the picker includes it.

Check

A step that resolves the value to select through an independent API call instead of reading the picker's options.

Test

Read the picker's rendered options, assert that the list has entries beyond the placeholder, select one of them, and read back the companion fields that the server derives.

CS-E2E-008, CS-UI-020