test(stack): close v3 query-permutation coverage gaps (neq, contained_by, range)#587
Conversation
…_by, range) Follow-up to the protect-ffi 0.28 PR. Adversarial coverage verification found four public two-arg eql_v3.* functions the SDK can drive but no test exercised. Add data-driven proofs across every applicable domain in matrix-live-pg (57 -> 86): - eql_v3.neq / <> — new it.each(eqDomains): operand = samples[0]; neq selects the other row (idB) and excludes the matching row (idA). - eql_v3.contained_by / <@ — new it.each(matchDomains): the dual of contains; operand covers row idA's token set so idA is contained_by it and idB is not. - explicit two-bound range + strict gt/lt — new it.each(orderingDomains): over the distinct-sample ORDER_RUN_ID rows, gte+lte (inclusive [lo,hi]) selects all, gt+lt (exclusive) selects only the interior. Closes the gap where the 14 numeric/date/ts ORE domains' "range" test actually ran eql_v3.eq. - rename the misleading ord test "ORE range selects the exact row" -> "equality-via-ORE selects the exact row" (accurate: it runs eq / degenerate range). Operands reuse the already-encrypted ORDER_RUN_ID ciphertexts (encModels) — no extra encryption. All new proofs use boolean comparison operators (ORE-correct on superuser AND non-superuser Postgres — verified green on a non-superuser local role), never ORDER BY ord_term. No src changes. matrix-live-pg 86/86, types 60/60.
|
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Follow-up stacked on the EQL v3 / protect-ffi 0.28 work (PR #575
chore/eql-v3-ffi-0-28, now merged intofeat/eql-v3-text-search-schema). Closes the four query-permutation coverage gaps found by adversarial verification. Additive tests only — nosrc/changes.Gaps closed (all in
matrix-live-pg.test.ts, 57 → 86 tests)eql_v3.neq/<>—it.each(eqDomains):neq(samples[0])selects the other row, excludes the matching one.eql_v3.contained_by/<@—it.each(matchDomains): dual ofcontains; operand covers row idA's token set → idA contained_by, idB excluded.gt/lt—it.each(orderingDomains): over the distinct-sample rows,gte+lte(inclusive) selects all,gt+lt(exclusive) selects only the interior. Previously the 14 numeric/date/ts ORE domains' "range" test actually raneql_v3.eq."ORE range selects the exact row"→"equality-via-ORE selects the exact row".Notes
ORDER_RUN_IDciphertexts — no extra encryption.ORDER BY ord_term.matrix-live-pg86/86,test:types60/60.Summary by CodeRabbit