diff --git a/scripts/check_app_discovery_live.sh b/scripts/check_app_discovery_live.sh index 3c5a7fc..28c5d69 100644 --- a/scripts/check_app_discovery_live.sh +++ b/scripts/check_app_discovery_live.sh @@ -103,9 +103,9 @@ grep -Fq 'const FEAT_T={en:{0:"Choose A or B on a question."' "$tmp/dotchi.html" fetch '/support/debate-me/' 'debate-me.html' # The post-GSC 2026-11-11 snippet must be live; rejecting the old SEO # title prevents a GitHub merge from being mistaken for a published change. -grep -Fq 'Debate Me – Practice Debating with AI on Android | SK APPS' "$tmp/debate-me.html" || { echo 'FAIL Debate Me new SEO title not live' >&2; exit 1; } -grep -Fq 'content="Want to get better at debating? Debate Me lets you challenge an AI opponent' "$tmp/debate-me.html" || { echo 'FAIL Debate Me new search description not live' >&2; exit 1; } -grep -Fq '' "$tmp/debate-me.html" || { echo 'FAIL Debate Me OG title not live' >&2; exit 1; } +grep -Fq 'Debate Me – AI Debate Practice App for Android | SK APPS' "$tmp/debate-me.html" || { echo 'FAIL Debate Me new SEO title not live' >&2; exit 1; } +grep -Fq 'content="Debate Me is an Android AI debate practice app. Choose a topic, practise claims and rebuttals with an AI opponent' "$tmp/debate-me.html" || { echo 'FAIL Debate Me new search description not live' >&2; exit 1; } +grep -Fq '' "$tmp/debate-me.html" || { echo 'FAIL Debate Me OG title not live' >&2; exit 1; } grep -Fq 'data-position="hero"' "$tmp/debate-me.html" || { echo 'FAIL Debate Me first-screen Play CTA not live' >&2; exit 1; } grep -Fq 'data-position="details"' "$tmp/debate-me.html" || { echo 'FAIL Debate Me details Play CTA missing' >&2; exit 1; } grep -Fq 'utm_campaign=support_debate-me' "$tmp/debate-me.html" || { echo 'FAIL Debate Me published Play campaign attribution missing' >&2; exit 1; } @@ -160,6 +160,22 @@ grep -Fq 'support_future_me_hero' "$tmp/futureme.html" || { echo 'FAIL FutureMe if grep -Eiq 'Letters to future self|Time capsule feature|FutureMe Premium.*[0-9]+/(month|year)|FutureMe Premium 提供月度|NT\\$150/月' "$tmp/futureme.html"; then echo 'FAIL FutureMe support page contains outdated feature or pricing claims' >&2; exit 1 fi +# App referral feature release proof (PR #133): source merge is not +# production delivery. A 200 HTML fallback at the .js URL is NOT proof; +# check the exact asset content and three first-party landing-page script tags. +# This remains a read-only smoke check, not a real user share or Play install. +fetch '/scripts/app-share.js' 'app-share.js' +grep -Fq 'app_support_share' "$tmp/app-share.js" || { echo 'FAIL app share asset is absent or an HTML fallback' >&2; exit 1; } +grep -Fq 'navigator.share' "$tmp/app-share.js" || { echo 'FAIL native share flow not deployed' >&2; exit 1; } +grep -Fq 'navigator.clipboard.writeText' "$tmp/app-share.js" || { echo 'FAIL share copy fallback missing' >&2; exit 1; } +fetch '/support/tappitsu-battle/' 'tappitsu-battle.html' +for entry in 'debate-me:debate-me' 'futureme:future-me' 'tappitsu-battle:tappitsu-battle'; do + IFS=: read -r html_file slug <<< "$entry" + grep -Fq "src=\"/scripts/app-share.js\" data-app-share-slug=\"$slug\"" "$tmp/$html_file.html" \ + || { echo "FAIL opt-in sharing for $slug not deployed to its landing HTML" >&2; exit 1; } +done +echo 'PASS: public app sharing script and three localized app landing bindings present (browser QA still required)' + # Newly indexed bilingual AI debate practice articles must be live and # point to real Android app destinations, not just appear in sitemap/source. fetch '/guides/ai-debate-practice/' 'ai-debate-practice.html' diff --git a/scripts/test_live_smoke_source_parity.py b/scripts/test_live_smoke_source_parity.py index ee0b029..a6d2b18 100644 --- a/scripts/test_live_smoke_source_parity.py +++ b/scripts/test_live_smoke_source_parity.py @@ -35,6 +35,8 @@ "instant-judge.html": "support/instant-judge/index.html", "roastme.html": "support/roast-me/index.html", "futureme.html": "support/future-me/index.html", + "app-share.js": "scripts/app-share.js", + "tappitsu-battle.html": "support/tappitsu-battle/index.html", } # Check only literal, single-quoted -Fq source assertions. Double-quoted @@ -95,6 +97,13 @@ def test_expected_app_pages_are_actually_represented(self): self.assertIn("one-tap-routine.html", report["files"]) self.assertIn("taletime.html", report["files"]) self.assertIn("futureme.html", report["files"]) + self.assertIn("app-share.js", report["files"]) + # Tappitsu binding is checked inside the shell loop (dynamic $slug), + # so the literal-only scanner deliberately does not claim it verified + # that loop by expanding variable values. + self.assertIn("tappitsu-battle.html", SOURCE_PATHS) + self.assertIn("fetch '/support/tappitsu-battle/' 'tappitsu-battle.html'", smoke) + self.assertIn("data-app-share-slug=", smoke) self.assertIn("sitemap.xml", report["files"]) self.assertIn("ai-debate-practice.html", report["files"]) self.assertIn("ai-debate-practice-ja.html", report["files"]) diff --git a/scripts/test_press_kit.py b/scripts/test_press_kit.py index 92d3582..d9ee373 100644 --- a/scripts/test_press_kit.py +++ b/scripts/test_press_kit.py @@ -91,8 +91,8 @@ def test_live_smoke_checks_all_press_locales_and_latest_support(self): self.assertIn("'press_app_click'", smoke) self.assertIn("'download_click'", smoke) self.assertIn("BrainBurst – Daily Trivia & 1v1 Quiz Battles on Android", smoke) - self.assertIn("Debate Me – Practice Debating with AI on Android | SK APPS", smoke) - self.assertIn('', smoke) + self.assertIn("Debate Me – AI Debate Practice App for Android | SK APPS", smoke) + self.assertIn('', smoke) self.assertNotIn("Debate Me: Practice Arguments with AI | Android App", smoke) self.assertNotIn("Debate Me – Free AI Debate App for Android | SK APPS", smoke) self.assertIn("utm_campaign=support_debate-me", smoke) diff --git a/tests/app-support-share.test.mjs b/tests/app-support-share.test.mjs index 6ff7a18..607bf3e 100644 --- a/tests/app-support-share.test.mjs +++ b/tests/app-support-share.test.mjs @@ -64,3 +64,21 @@ test("VPS and offline release bundle both contain the shared asset", () => { assert.match(manifest, /files=\(scripts\/app-share\.js index\.html/); assert.match(bundle, /len\(apps\) != 31/); }); + + +test("live smoke rejects missing share assets or mismatched app landing bindings", () => { + const smoke = read("scripts/check_app_discovery_live.sh"); + assert.match(smoke, /fetch '\/scripts\/app-share\.js' 'app-share\.js'/); + assert.match(smoke, /grep -Fq 'app_support_share' "\$tmp\/app-share\.js"/); + assert.match(smoke, /grep -Fq 'navigator\.share' "\$tmp\/app-share\.js"/); + assert.match(smoke, /grep -Fq 'navigator\.clipboard\.writeText' "\$tmp\/app-share\.js"/); + assert.match(smoke, /fetch '\/support\/tappitsu-battle\/' 'tappitsu-battle\.html'/); + assert.match(smoke, /'debate-me:debate-me' 'futureme:future-me' 'tappitsu-battle:tappitsu-battle'/); + assert.match(smoke, /data-app-share-slug=/); + assert.match(smoke, /FAIL opt-in sharing for \$slug not deployed/); + assert.match(smoke, /browser QA still required/); + // Source-only and read-only: do not permit the public smoke to publish + // or misstate a share tap as an install or an inbound human visitor. + assert.doesNotMatch(smoke, /^\s*(?:rsync|ssh|gh workflow run)\b/m); + assert.doesNotMatch(smoke, /install_completed/i); +}); diff --git a/tests/debate-me-support-growth.test.mjs b/tests/debate-me-support-growth.test.mjs index 1fc48cc..ff4e129 100644 --- a/tests/debate-me-support-growth.test.mjs +++ b/tests/debate-me-support-growth.test.mjs @@ -11,8 +11,8 @@ function dictionary(name, after) { return runInNewContext('('+match[1]+')'); } test('first paint shows real AI debate and never a food spinner', () => { - assert.match(html, /Debate Me – Practice Debating with AI on Android \| SK APPS<\/title>/); - assert.match(html, /<meta property="og:title" content="Debate Me – Practice Debating with AI on Android \| SK APPS">/); + assert.match(html, /<title>Debate Me – AI Debate Practice App for Android \| SK APPS<\/title>/); + assert.match(html, /<meta property="og:title" content="Debate Me – AI Debate Practice App for Android \| SK APPS">/); assert.match(html, /<h1>Debate Me<\/h1>/); assert.match(html, /<div class="hero-emoji">🗣️<\/div>/); assert.match(html, /<div class="hero-cat">Education<\/div>/); @@ -62,7 +62,7 @@ test('manual VPS publishing includes the landing and its read-only live validati assert.match(live,/fetch '\/support\/debate-me\/' 'debate-me.html'/); assert.match(live,/FAIL Debate Me page still describes cooking/); assert.match(live,/FAIL Debate Me first-screen Play CTA not live/); - assert.match(live, /Debate Me – Practice Debating with AI on Android/); + assert.match(live, /Debate Me – AI Debate Practice App for Android/); assert.match(live, /FAIL Debate Me new SEO title not live/); assert.match(live, /FAIL Debate Me new search description not live/); assert.doesNotMatch(live, /grep -Fq 'AI Debate Practice & Feedback'/); @@ -78,6 +78,6 @@ test('search snippets match the visible Debate Me product and schema', () => { assert.match(description, /Debate Me/); assert.match(description, /AI opponent/); assert.match(description, /review feedback/); - assert.match(description, /on Google Play/); + assert.match(description, /Explore Google Play/); assert.equal(JSON.parse(schema).description, description); });