@nsshunt/ststestrunner 1.1.125 → 1.1.126
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ststestrunner.mjs
CHANGED
|
@@ -2163,15 +2163,31 @@ var TestCaseFhir07 = class extends TestCaseFhirQueryBase {
|
|
|
2163
2163
|
const __snapshot4 = this._CheckOutputLongDurationError(__snapshot3, "await this.GetResource()");
|
|
2164
2164
|
if (retVal.status === StatusCodes.UNAUTHORIZED) throw new Error("UNAUTHORIZED");
|
|
2165
2165
|
const resource = retVal.body;
|
|
2166
|
+
const patchText = `Json Patched record TestCaseFhir07 ${this.runner.iteration}`;
|
|
2166
2167
|
const observer = fast_json_patch_default.observe(resource);
|
|
2167
|
-
resource.text.div =
|
|
2168
|
+
resource.text.div = patchText;
|
|
2168
2169
|
const patchRecord = fast_json_patch_default.generate(observer);
|
|
2169
2170
|
const retValPatched = await client.PatchResource("Person", personRecord.id, patchRecord, `application/json-patch+json`, `W/"3"`);
|
|
2170
2171
|
this._CheckOutputLongDurationError(__snapshot4, "await this.PatchResource()");
|
|
2171
2172
|
if (retValPatched.status === StatusCodes.UNAUTHORIZED) throw new Error("UNAUTHORIZED");
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2173
|
+
const retRecordCheck = { ...retValPatched.body };
|
|
2174
|
+
personRecord.text.div = patchText;
|
|
2175
|
+
personRecord.meta.versionId = "4";
|
|
2176
|
+
delete personRecord.meta.lastUpdated;
|
|
2177
|
+
delete retRecordCheck.meta.lastUpdated;
|
|
2178
|
+
const p1 = JSON.stringify(personRecord);
|
|
2179
|
+
const p2 = JSON.stringify(retRecordCheck);
|
|
2180
|
+
if (p1.localeCompare(p2) !== 0) {
|
|
2181
|
+
this.runner.instrumentData.errorCount++;
|
|
2182
|
+
console.log("");
|
|
2183
|
+
console.log(chalk.red(` ==> 7.1 ************************************************************************************************`));
|
|
2184
|
+
console.log(p1);
|
|
2185
|
+
console.log(chalk.red(`************************************************************************************************`));
|
|
2186
|
+
console.log(p2);
|
|
2187
|
+
console.log(chalk.red(`************************************************************************************************`));
|
|
2188
|
+
console.log("");
|
|
2189
|
+
process.exit(1);
|
|
2190
|
+
}
|
|
2175
2191
|
return retValPatched.body;
|
|
2176
2192
|
};
|
|
2177
2193
|
};
|