Skip to content

[Bug]: Filter and RemoveKey regression assertions accept stale extra entries #1184

Description

@dwcullop

Please note we can't commit to any timeline.

Describe the bug 🐞

The added full-collection assertions use Assert.Equivalent with its default strict:false setting. That allows extra actual entries, so the tests can accept the precise stale-item failure they intend to reject. This is a test defect, not an xUnit library defect.

Step to reproduce

Use the existing refresh/removal fixture and omit its production removal operation as a controlled mutation. Compare the same fixture with its old non-strict assertions and corrected strict assertions.

Regression tests/checks:

AutoRefreshRemoveKeyFilterUpdate_CollectionUpdated; AutoRefreshFilterRemoveKeyUpdate_CollectionUpdated

Reproduction repository

https://github.com/reactivemarbles/DynamicData/tree/85ee49cfd54d8782c36ed137886d318e942345c4

Regression tests and fixes:
https://github.com/reactivemarbles/DynamicData/tree/u/dacullop/main/pr-1165-review

Expected behavior

A test claiming the exact filtered collection must fail when an excluded or duplicate entry remains.

Screenshots 🖼️

N/A.

IDE

N/A; command-line reproduction.

Operating system

Windows.

Version

.NET SDK 10.0.401; net9.0 test target.

Device

N/A.

DynamicData Version

Main 10.0-preview at 85ee49c. The related 9.5 candidate is PR #1165 at 3d76872.

Additional information ℹ️

In an isolated baseline snapshot, removing the Replace true-to-false downstream removal makes the real integration fixture pass with strict:false. The identical mutation fails with strict:true: Assert.Equivalent reports an excluded item left over in the actual collection. The live source is not mutated, and corrected strict assertions pass with normal production code.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions