fix(page-data): scope finish guard to current delivery
This commit is contained in:
@@ -326,7 +326,7 @@ test('integration: H5 finish guard triggers repair prompt for invalid survey htm
|
||||
}
|
||||
});
|
||||
|
||||
test('integration: finish guard repairs historical unbound Page Data html without a current write', async () => {
|
||||
test('integration: finish guard does not repair historical Page Data html without a current write', async () => {
|
||||
const workspaceRoot = fs.mkdtempSync(path.join(os.tmpdir(), 'page-data-historical-skip-'));
|
||||
try {
|
||||
await setupSurveyWorkspace(workspaceRoot);
|
||||
@@ -342,9 +342,9 @@ test('integration: finish guard repairs historical unbound Page Data html withou
|
||||
userText: '确认发布',
|
||||
tkmindProxy: { async submitSessionReplyForUser() { throw new Error('must not repair history'); } },
|
||||
});
|
||||
assert.equal(result.structuralPageData, true);
|
||||
assert.equal(result.relevantFiles.length, 1);
|
||||
assert.equal(result.needsRepair, true);
|
||||
assert.equal(result.structuralPageData, false);
|
||||
assert.equal(result.relevantFiles.length, 0);
|
||||
assert.equal(result.needsRepair, false);
|
||||
assert.equal(result.triggered, undefined);
|
||||
} finally {
|
||||
fs.rmSync(workspaceRoot, { recursive: true, force: true });
|
||||
|
||||
Reference in New Issue
Block a user