Skip to content

A one-of-a-kind resume builder that keeps your privacy in mind. Completely secure, customizable, portable, open-source and free forever. Try it out today!

test(career): prove composed question and provenance contracts

Amruth Pillai13cb06ead219
diff --git a/apps/mobile/scripts/experience.test.mjs b/apps/mobile/scripts/experience.test.mjs
index 0bc4e1a8c..ddf34fa16 100644
--- a/apps/mobile/scripts/experience.test.mjs
+++ b/apps/mobile/scripts/experience.test.mjs
@@ -4451,6 +4451,7 @@ const { AnswerCard: NativeAnswerCard } = load(
"../shell": {},
"../state": {},
"@/api/client": {},
+ "@/auth/session": { getAccountScope: () => "fixture" },
"@/draft": {},
"@/features/ai/providers": { useHasAIProvider: () => ({ defaultProvider: { id: "fixture" } }) },
"@/features/application-detail/sections": {},
@@ -4493,3 +4494,15 @@ await settle();
assert.deepEqual(provenanceSaves[1].patch.aiOperationIds, ["prior-op"]);
assert.deepEqual(provenanceSaves[1].expected.aiOperationIds, ["prior-op", "next-op"]);
console.log("PASS native answer Accept/Undo preserves actual request sources with the reviewed content");
+
+reset();
+provenanceAnswer = { ...provenanceAnswer, question: "Original question from form" };
+provenanceView();
+provenanceAnswer = { ...provenanceAnswer, question: "Corrected question from another device" };
+provenanceView();
+assert.equal(
+ nodes(provenanceView()).find((node) => node.type === "Block").props.title,
+ "Corrected question from another device",
+ "Canonical question correction replaces an untouched native draft instead of autosaving the old wording",
+);
+console.log("PASS native canonical question wording updates an untouched draft");
diff --git a/docs/spec.json b/docs/spec.json
index 402a7cded..8997b78f0 100644
--- a/docs/spec.json
+++ b/docs/spec.json
@@ -61757,6 +61757,15 @@
"items": {
"type": "string"
}
+ },
+ "aiOperationIds": {
+ "type": "array",
+ "maxItems": 1000,
+ "items": {
+ "type": "string",
+ "minLength": 1,
+ "maxLength": 64
+ }
}
},
"required": [
@@ -61807,6 +61816,15 @@
"items": {
"type": "string"
}
+ },
+ "aiOperationIds": {
+ "type": "array",
+ "maxItems": 1000,
+ "items": {
+ "type": "string",
+ "minLength": 1,
+ "maxLength": 64
+ }
}
},
"required": [