Skip to content

Commit e89ed9e

Browse files
committed
test(release): follow intentional #53/#63/#71/#77/#78 changes in live and unit gates
The deployed pages were correct but the gates still pinned old values: - check_growth_live: #77 input handler (clears dedupe key, never reports per keystroke) - check_app_discovery_live: #78 Debate Me title, #53 robots Allow: /icons/ - catalog-growth: #71 ?goal= landing needs URL/location/history/reset in sandbox; #63 app_detail_click - debate-me / dotchi: current title; sitemap lastmod must not regress (not equal a fixed date) python 72/72, node tests 52/52 (was 47/52 on main), live 92/92. Claude-Session: https://claude.ai/code/session_01J5anYNmtTi1EKefKjB5aoV
1 parent 58d77f3 commit e89ed9e

7 files changed

Lines changed: 19 additions & 12 deletions

‎scripts/check_app_discovery_live.sh‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ grep -Fq 'data-position="hero"' "$tmp/dotchi.html" || { echo 'FAIL Dotchi store
6161
grep -Fq 'const FEAT_T={en:{0:"Choose A or B on a question."' "$tmp/dotchi.html" || { echo 'FAIL Dotchi translated feature claims still stale' >&2; exit 1; }
6262
# Read-only release gate for the recently corrected Debate Me SEO landing.
6363
fetch '/support/debate-me/' 'debate-me.html'
64-
grep -Fq 'AI Debate Practice & Argument Skills' "$tmp/debate-me.html" || grep -Fq 'AI Debate Practice & Argument Skills' "$tmp/debate-me.html" || { echo 'FAIL Debate Me product title is not live' >&2; exit 1; }
64+
# #78 retitled the page from GSC evidence: "AI Debate Practice & Feedback".
65+
grep -Fq 'AI Debate Practice & Feedback' "$tmp/debate-me.html" || grep -Fq 'AI Debate Practice & Feedback' "$tmp/debate-me.html" || { echo 'FAIL Debate Me product title is not live' >&2; exit 1; }
6566
grep -Fq 'data-position="hero"' "$tmp/debate-me.html" || { echo 'FAIL Debate Me first-screen Play CTA not live' >&2; exit 1; }
6667
grep -Fq 'data-position="details"' "$tmp/debate-me.html" || { echo 'FAIL Debate Me details Play CTA missing' >&2; exit 1; }
6768
grep -Fq 'support_debate_me_hero' "$tmp/debate-me.html" || { echo 'FAIL Debate Me Play attribution missing' >&2; exit 1; }
@@ -111,5 +112,6 @@ if grep -Eiq 'Letters to future self|Time capsule feature|FutureMe Premium.*[0-9
111112
echo 'FAIL FutureMe support page contains outdated feature or pricing claims' >&2; exit 1
112113
fi
113114
fetch '/robots.txt' 'robots.txt'
114-
grep -Fq 'Allow: /icons/apps/' "$tmp/robots.txt" || { echo 'FAIL Google image crawl allow not live' >&2; exit 1; }
115+
# #53 broadened the allow to /icons/ (covers /icons/apps/).
116+
grep -Eq '^Allow: /icons/(apps/)?$' "$tmp/robots.txt" || { echo 'FAIL Google image crawl allow not live' >&2; exit 1; }
115117
echo 'PASS: catalog, guides, priority search landings, store CTAs, icon crawl policy and sitemap current (HTTP 200)'

‎scripts/check_growth_live.py‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,10 @@ def check(path, key, valid):
8383
check("/apps", "store_click_tracking", "catalog_store_click" in catalog and "download_click" in catalog)
8484
check("/apps", "detail_click_tracking", "catalog_app_detail_click" in catalog)
8585
check("/apps", "finalized_search_analytics",
86-
"input.addEventListener('input', render)" in catalog and
86+
# #77: the input handler re-renders and clears the dedupe key, but never reports per keystroke.
87+
"input.addEventListener('input', () => {" in catalog and
88+
"if (!clean(input.value)) lastReportedSearch = '';" in catalog and
89+
"input.addEventListener('input', reportSearch)" not in catalog and
8790
"input.addEventListener('blur', reportSearch)" in catalog and
8891
"if (event.key === 'Enter') reportSearch()" in catalog and
8992
"query === lastReportedSearch" in catalog and

‎scripts/test_growth_live.py‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ def valid_pages():
2626
pages["/apps"] = (
2727
'<script type="application/ld+json">' + json.dumps(listing) + '</script>' +
2828
cards + " catalog_store_click download_click catalog_app_detail_click " +
29-
"input.addEventListener('input', render) input.addEventListener('blur', reportSearch) " +
29+
"input.addEventListener('input', () => { if (!clean(input.value)) lastReportedSearch = ''; render(); }); " +
30+
"input.addEventListener('blur', reportSearch) " +
3031
"if (event.key === 'Enter') reportSearch() query === lastReportedSearch " +
3132
"lastReportedSearch = query " +
3233
"const app = slug(card), content = clean((card.textContent || '') + ' ' + app; app.replace(/-/g, ' ')" +
@@ -217,7 +218,7 @@ def test_store_schema_package_mismatch_fails(self):
217218
def test_first_keystroke_analytics_rejected(self):
218219
data = valid_pages()
219220
data["/apps"] = data["/apps"].replace(
220-
"input.addEventListener('input', render)",
221+
"input.addEventListener('input', () => { if (!clean(input.value)) lastReportedSearch = ''; render(); }); ",
221222
"input.addEventListener('input', reportSearch)")
222223
self.assertFalse(inspect(data)["passed"])
223224

‎tests/catalog-growth.test.mjs‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ test('filters work client-side without tracking raw search text',()=>{
2626
const source=scripts.find(s=>s.includes('catalog_store_click'));
2727
assert.ok(source); new Script(source);
2828
function el(extra={}) {return {events:{},hidden:false,...extra,addEventListener(name,fn){this.events[name]=fn;},setAttribute(key,value){this[key]=value;}}}
29-
const input=el({value:''}),count=el({textContent:''}),empty=el();
29+
const input=el({value:''}),count=el({textContent:''}),empty=el(),reset=el({focus(){}});
3030
const buttons=['all','quick-games','habits','decisions','ai'].map(goal=>el({dataset:{goal}}));
3131
const cards=[
3232
el({textContent:'Blur: Guess the Image Guess the photo',querySelector:()=>({getAttribute:()=> 'icons/apps/blur.png'})}),
3333
el({textContent:'FutureMe - AI Prediction write future letters',querySelector:()=>({getAttribute:()=> 'icons/apps/future-me.png'})}),
3434
el({textContent:'Food Roulette pick a restaurant',querySelector:()=>({getAttribute:()=> 'icons/apps/food-roulette.png'})}),
3535
];
3636
const events=[];
37-
runInNewContext(source,{document:{getElementById(id){return {'find-app':input,'finder-count':count,'finder-empty':empty}[id];},querySelectorAll(q){return q==='.grid .app-card'?cards:buttons;}},window:{gtag(...args){events.push(args);}}});
37+
runInNewContext(source,{document:{referrer:'',getElementById(id){return {'find-app':input,'finder-count':count,'finder-empty':empty,'finder-reset':reset}[id];},querySelectorAll(q){return q==='.grid .app-card'?cards:q==='[data-detail-app]'?[]:buttons;}},URLSearchParams,URL,window:{location:{search:'',href:'https://appdevelopsk.com/apps',origin:'https://appdevelopsk.com'},history:{state:null,replaceState(){}},gtag(...args){events.push(args);}}});
3838
assert.equal(count.textContent,'3 apps shown');
3939
buttons[1].events.click();
4040
assert.equal(count.textContent,'1 apps shown');
@@ -155,5 +155,5 @@ test('home features public Dotchi instead of an unavailable app, with 17 languag
155155
assert.equal(typeof translations[lang].twotaku,'string',lang+' must localize Dotchi caption');
156156
assert.ok(translations[lang].twotaku.length>=12,lang+' missing meaningful caption');
157157
}
158-
assert.match(home,/gtag\('event', 'app_view'/,'homepage app-card clicks remain measurable');
158+
assert.match(home,/gtag\('event', 'app_detail_click', \{[^}]*placement: 'homepage_card'/,'homepage app-card clicks remain measurable');
159159
});

‎tests/debate-me-support-growth.test.mjs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ function dictionary(name, after) {
1111
return runInNewContext('('+match[1]+')');
1212
}
1313
test('first paint shows real AI debate and never a food spinner', () => {
14-
assert.match(html, /<title>Debate Me: AI Debate Practice for Android/);
14+
assert.match(html, /<title>Debate Me – AI Debate Practice &(amp;)? Feedback/);
1515
assert.match(html, /<h1>Debate Me<\/h1>/);
1616
assert.match(html, /<div class="hero-emoji">🗣️<\/div>/);
1717
assert.match(html, /<div class="hero-cat">Education<\/div>/);

‎tests/dotchi-support-growth.test.mjs‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,5 +49,6 @@ test('Dotchi support publication is part of the non-destructive VPS release gate
4949
assert.match(release,/support\/twotaku\/index\.html/);
5050
assert.match(live,/support\/twotaku/);
5151
assert.match(live,/FAIL Dotchi anime-only support content still live/);
52-
assert.match(sitemap,/https:\/\/appdevelopsk\.com\/support\/twotaku\/<\/loc><lastmod>2026-10-27/);
52+
const dotchiLastmod=sitemap.match(/https:\/\/appdevelopsk\.com\/support\/twotaku\/<\/loc><lastmod>(\d{4}-\d{2}-\d{2})/)?.[1];
53+
assert.ok(dotchiLastmod&&dotchiLastmod>='2026-10-27','Dotchi sitemap lastmod must not regress before 2026-10-27');
5354
});

‎tests/search-landing-growth.test.mjs‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ test('unavailable Face Reaction Battle stays unavailable and offers distinct pub
5151

5252
test('public catalog icons are crawlable and explicit VPS release is non-destructive',()=>{
5353
const robots=read('robots.txt');
54-
assert.match(robots,/Allow: \/icons\/apps\//);
54+
assert.match(robots,/Allow: \/icons\/(apps\/)?$/m);
5555
const pub=read('scripts/publish_app_discovery.sh');
5656
assert.match(pub,/--dry-run/);
5757
assert.match(pub,/support\/brain-burst\/index\.html/);
@@ -65,7 +65,7 @@ test('public catalog icons are crawlable and explicit VPS release is non-destruc
6565
assert.doesNotMatch(pub,/^rsync[^\n]*--delete/m);
6666
const live=read('scripts/check_app_discovery_live.sh');
6767
assert.match(live,/data-position="hero"/);
68-
assert.match(live,/Allow: \/icons\/apps\//);
68+
assert.ok(live.includes("Allow: /icons/(apps/)?"));
6969
});
7070

7171
test('daily live acquisition check is read-only, scheduled and fails visibly on stale VPS',()=>{

0 commit comments

Comments
 (0)