elsa-core/test
Sipke Schoorstra fe9217bdfa
test(labels): share InMemory/EF store conformance scenarios (#8122)
* test(labels): share InMemory/EF store conformance scenarios

Add one abstract Labels store suite and run it against InMemory and
EF Core (SQLite) so tenant isolation, NormalizedName uniqueness,
cascade delete, ReplaceAsync, and association lookups stay aligned.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

* test(labels): drop provider-specific uniqueness and paging asserts

SaveMany name swaps trip EF BulkUpsert unique indexes, and Memory
ToPage counts after Skip/Take. Keep the shared matrix on contracts
both InMemory and EF/SQLite honor.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

* test(labels): map conformance matrix to the #8091 lock list

Keep one scenario per issue invariant so the InMemory/EF harness stays
small and readable: cascade delete, ReplaceAsync, association
finds/deletes, ListAsync order/paging, tenant stamp/isolation, and
per-tenant NormalizedName uniqueness.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

* test(labels): cover cross-tenant lookup conformance

* test(labels): use Path.Join for sqlite fixture

* test(labels): lock ID-only ReplaceAsync and SaveMany tenant stamp

Vary every field except Id on the removed association so ReplaceAsync
cannot match the stored row by payload. Also stamp null-tenant batches
through SaveManyAsync on both label and association stores.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

* test(labels): stamp null TenantId under a named ambient tenant

Cover SaveAsync and SaveManyAsync for labels and associations when
the ambient tenant is tenant-a, so a default-only stamp cannot pass.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

* test(labels): reject tenant-A association leakage under tenant-B

Tenant-B FindByVersion and FindByLabelIds now require assoc-b and
assoc-star, and fail if assoc-a is visible.

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
2026-09-13 18:58:36 +02:00
..
component test(workflows-api): pin that a new read-only workflow can be imported (#8038) 2026-09-06 22:51:17 -07:00
integration test(labels): share InMemory/EF store conformance scenarios (#8122) 2026-09-13 18:58:36 +02:00
performance Add output converter support at binding boundaries 2026-08-21 22:22:46 +02:00
TlsSmoke [codex] Fix console log metadata and type resolution (#7542) 2026-05-30 22:52:01 +02:00
unit test(workflows): share Memory/EF store conformance scenarios (#8115) 2026-09-13 18:07:09 +02:00
Directory.Build.props Upgrade projects to target .NET 10, add conditional System.Linq.Async dependencies for compatibility with earlier frameworks, and update project files for consistency across the solution. (#7062) 2025-11-21 20:55:30 +01:00
Directory.Build.targets [codex] Harden initial security remediation slice (#7495) 2026-05-22 00:45:47 +02:00