docs: fix unsatisfiable exact-mode test in plan Task 9
The test used query 'certificat', which is a literal substring of the fixture's 'certificate' comment text. Exact mode is substring containment by design, so the query matched and the toHaveLength(0) assertion could never pass. Replaced with an insertion typo, which cannot be a substring of the shorter original. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 5
parent
8f29eb651d
commit
f41711a6ed
@@ -2878,8 +2878,12 @@ describe("Activity Ranking", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
test("exact mode finds nothing for a typo", async () => {
|
test("exact mode finds nothing for a typo", async () => {
|
||||||
|
// "certificatee" is an INSERTION typo: by construction it cannot be a
|
||||||
|
// substring of the shorter "certificate" in the fixture. A truncation
|
||||||
|
// typo like "certificat" would not work here — exact mode is substring
|
||||||
|
// containment, so a truncation still matches and the test could never pass.
|
||||||
const result = await listWorkPackageActivities(
|
const result = await listWorkPackageActivities(
|
||||||
{ workPackageId: 1, query: "certificat", matchMode: "exact" },
|
{ workPackageId: 1, query: "certificatee", matchMode: "exact" },
|
||||||
activitiesClient()
|
activitiesClient()
|
||||||
);
|
);
|
||||||
expect(result).toHaveLength(0);
|
expect(result).toHaveLength(0);
|
||||||
|
|||||||
Reference in New Issue
Block a user