Tests CRUD operations with 2-level nested embedded structs.
Validates that creating, reading, updating (instance and query-based),
and deleting records with nested embedded structs works end-to-end.
Tests that UUID fields inside embedded structs round-trip correctly.
UUID requires a type cast on databases that don’t support it natively
(e.g., SQLite stores it as text). This exercises the table_to_model
lifting path for embedded struct fields with non-trivial type mappings.
Tests partial updates of embedded struct fields via stmt::patch /
stmt::apply. This validates that individual fields within an embedded
struct can be updated without replacing the entire struct.
Tests partial updates of deeply nested embedded fields via nested
stmt::patch calls. Validates that patching a leaf field inside an
outer embedded struct updates only that leaf, leaving all other fields
unchanged in the database.
A data-carrying enum inside an embedded struct is replaced through a
patch on the struct: the record value is substituted into every column
of the nested enum (discriminant and variant fields), and the struct’s
other fields are untouched.
Tests partial updates of embedded fields using the query/filter-based path.
User::filter_by_id(id).update().address(stmt::patch(...)) follows a different
code path than the instance-based user.update().address(stmt::patch(...)),
so both need coverage.
Tests comparison operators (gt, lt, ge, le, ne) on embedded struct fields.
SQL-only: DynamoDB doesn’t support range queries on non-key attributes.
Validates that all comparison operators work correctly with embedded fields.
Tests querying by multiple embedded fields in a single query (AND conditions).
SQL-only: DynamoDB requires partition key in queries.
Validates that complex filters with multiple embedded fields work correctly.
Tests a unit enum embedded as a field inside an embedded struct (enum-in-struct nesting).
The struct flattens to columns including the enum’s discriminant column.
Tests UPDATE operations filtered by embedded struct fields.
SQL-only: DynamoDB requires partition key in queries/updates.
Validates that updates can target rows based on embedded field values.
Tests eq and ne on a whole multi-field embedded value: both
decompose into per-column comparisons — equality into AND, inequality
into OR — so ne matches rows differing in any column.