Allow fenced HTML tutorials in agent response smoke checks
wiki CI and deployment / verify-and-deploy (push) Successful in 12m37s

This commit is contained in:
2026-10-26 14:20:07 +08:00
parent 9e70ded549
commit 9a183aeeea
3 changed files with 16 additions and 1 deletions
+1 -1
View File
@@ -39,7 +39,7 @@ try {
const indexText=await indexResponse.text();
const id=indexText.match(/\/explore\/([a-f0-9]{24})/)?.[1];assert.ok(id);
const agent=await fetch(`http://127.0.0.1:${port}/explore/${id}?agent_mode=True`);
assert.equal(agent.status,200);assert.match(agent.headers.get('content-type'),/text\/plain/);assert.ok(!(await agent.text()).includes('<html'));
assert.equal(agent.status,200);assert.match(agent.headers.get('content-type'),/text\/plain/);const agentText=await agent.text();assert.match(agentText,/^# /);assert.doesNotMatch(agentText,/^\s*(?:<!doctype html|<html)/i);
const preview=await fetch(`http://127.0.0.1:${port}/api/preview?source=${encodeURIComponent('/skills/shadow-puppet/egret-example.png')}&width=480`);
assert.equal(preview.status,200);assert.match(preview.headers.get('content-type'),/image\/webp/);assert.ok((await preview.arrayBuffer()).byteLength<=100000);
console.log("Production smoke test passed");