test(release): fix fast-release guards after 143 migration
Memind CI / Test, build, and release guards (push) Failing after 3m19s
Memind CI / Test, build, and release guards (push) Failing after 3m19s
Use inline daily-news HTML fixture instead of missing dev page file, and assert WireGuard upstream 10.10.0.2 in canary release script test. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -50,6 +50,14 @@ const STARTUP_HTML = `<!DOCTYPE html><html><head><title>创业路演</title>
|
||||
<main><div class="section"><h2>愿景</h2><p>帮助每个团队拥有自己的 AI 大脑。</p></div></main>
|
||||
<footer><p data-mindspace-page-tag="platform-brand">TKMind · 智趣</p></footer></body></html>`;
|
||||
|
||||
const DAILY_NEWS_HTML = `<!DOCTYPE html><html lang="zh-CN"><head>
|
||||
<title>每日新闻早报 · 2026年9月10日</title>
|
||||
<meta name="description" content="2026年9月10日新闻热点摘要"></head><body>
|
||||
<div class="container"><div class="hero"><h1>📰 每日新闻早报</h1>
|
||||
<div class="date-badge">2026年9月10日 · 星期三</div></div>
|
||||
<div class="section" id="headlines"><div class="card"><h3>示例热点</h3><p>这是示例正文。</p></div></div>
|
||||
</div></body></html>`;
|
||||
|
||||
test('convertGenericPageHtmlToWechatArticle extracts title and body', () => {
|
||||
const article = convertGenericPageHtmlToWechatArticle(SAMPLE_HTML, {
|
||||
pageTitle: '测试页面',
|
||||
@@ -73,9 +81,8 @@ test('resolvePagePublicUrl prefers publication slug url over empty workspace pat
|
||||
});
|
||||
|
||||
test('daily-news draft includes read original when publicUrl is present', () => {
|
||||
const html = fs.readFileSync('public/dev/tkmind-upgrade-sep2026.html', 'utf8');
|
||||
const article = buildDailyNewsWechatDraftArticle({
|
||||
html,
|
||||
html: DAILY_NEWS_HTML,
|
||||
publicUrl: 'https://m.tkmind.cn/u/john/pages/tkmind-upgrade-sep2026',
|
||||
qrcodeImageUrl: 'https://mmbiz.qpic.cn/qrcode.png',
|
||||
});
|
||||
|
||||
@@ -208,7 +208,7 @@ test('production canary keeps stable 8081 live and switches only after verified
|
||||
assert.ok(edgeSwitch > tunnelStart);
|
||||
assert.ok(fallbackProbe > edgeSwitch);
|
||||
assert.match(source, /restore_edge_to_stable/);
|
||||
assert.match(source, /proxy_pass http:\/\/58\.38\.22\.103:8081;/);
|
||||
assert.match(source, /proxy_pass http:\/\/10\.10\.0\.2:8081;/);
|
||||
assert.match(source, /proxy_pass http:\/\/127\.0\.0\.1:\$\{CANARY_TUNNEL_REMOTE_PORT\};/);
|
||||
assert.match(source, /nginx -t/);
|
||||
assert.match(source, /CANARY_PROXY_PORT=18082/);
|
||||
|
||||
Reference in New Issue
Block a user