chore: remove leftovers of the deleted onboarding AI offer and badge

The end-to-end setup still seeded the shared-provider offer's account
and captured its session, although the journey that used it is gone.
Three comments still pointed at what was removed: the tour launcher
cited the deleted personal-record badge as its model, the personal
record worker said the badge still renders, and the morning briefing
push said a concerning reading goes out as an anomaly notification,
which nothing sends.
This commit is contained in:
Marc-André Bombeck committed 2026-11-11 21:47:54 +01:00
1 parent aacf06b7b3
commit ce377ef56d
4 files changed
+6 -28

No files matched your search

-21
View File
@@ -717,21 +717,6 @@ export const E2E_SETUP_LOCALE = {
role: "USER",
} as const;
/**
* v1.38.19 — the shared-provider offer's own account.
*
* Its journey seeds INSTANCE-wide state (the operator key's presence and the
* provider-health ledger the tri-state folds) and mints a consent receipt on
* the account, so it cannot share one with a journey that asserts a module
* map or a tile order.
*/
export const E2E_SETUP_AI_OFFER = {
email: "e2e-setup-ai-offer@healthlog.test",
username: "e2e-setup-ai-offer",
password: "Ao6!Zd3fB9qMv2Rk",
role: "USER",
} as const;
export const SETUP_BP_STORAGE_STATE_PATH = resolve(
process.cwd(),
"e2e/setup/storageStateSetupBp.json",
@@ -760,10 +745,6 @@ export const SETUP_LOCALE_STORAGE_STATE_PATH = resolve(
process.cwd(),
"e2e/setup/storageStateSetupLocale.json",
);
export const SETUP_AI_OFFER_STORAGE_STATE_PATH = resolve(
process.cwd(),
"e2e/setup/storageStateSetupAiOffer.json",
);
const SETUP_FLOW_ACCOUNTS = [
E2E_SETUP_BP,
@@ -772,7 +753,6 @@ const SETUP_FLOW_ACCOUNTS = [
E2E_SETUP_CHILD,
E2E_SETUP_A11Y,
E2E_SETUP_LOCALE,
E2E_SETUP_AI_OFFER,
E2E_SETUP_CONNECT,
] as const;
@@ -1882,7 +1862,6 @@ export default async function globalSetup(config: FullConfig): Promise<void> {
await capture(E2E_SETUP_A11Y, SETUP_A11Y_STORAGE_STATE_PATH);
await capture(E2E_SETUP_LOCALE, SETUP_LOCALE_STORAGE_STATE_PATH);
await capture(E2E_SETUP_CONNECT, SETUP_CONNECT_STORAGE_STATE_PATH);
await capture(E2E_SETUP_AI_OFFER, SETUP_AI_OFFER_STORAGE_STATE_PATH);
await capture(E2E_SETUP_CHILD, SETUP_CHILD_STORAGE_STATE_PATH);
await pool.query(
`UPDATE users SET totp_confirmed_at = $2 WHERE username = $1`,
+1 -2
View File
@@ -244,8 +244,7 @@ export function TourLauncher({ ready = true }: TourLauncherProps) {
// v1.4.47 — clock reading for the 24 h auto-launch gate. The
// useState lazy-initialiser runs once at mount; subsequent re-renders
// reuse the same value. This keeps the render path pure (React's
// purity linter rejects a bare `Date.now()` reference in render) and
// matches the established pattern in `personal-record-badge.tsx`:
// purity linter rejects a bare `Date.now()` reference in render):
// capture the clock at a stable boundary, then derive freshness from
// it. The launcher only consults this value once per (user, flag)
// tuple via the `decidedFor` guard, so a mount that takes ten
+3 -3
View File
@@ -22,9 +22,9 @@
* signal's headline without a figure in it, "your score is ready", or the
* honest all-clear — never a reading, a dose or the score itself, since the
* push lands on a locked phone). It is dispatched NON-URGENT, so it never escalates to a
* Focus-bypassing / time-sensitive delivery — a concerning reading always stays
* on `MEASUREMENT_ANOMALY`, never here. It fires ONLY inside a local morning
* window, which is the quiet-hours guarantee for this nudge.
* Focus-bypassing / time-sensitive delivery, and a concerning reading is never
* pushed through it. It fires ONLY inside a local morning window, which is the
* quiet-hours guarantee for this nudge.
*/
import { SESSION_USER_SELECT, type SessionUser } from "@/lib/auth/session-user";
import type { PrismaClient } from "@/generated/prisma/client";
@@ -79,8 +79,8 @@ export interface DetectPersonalRecordsOptions {
* Set when a batch ingest crosses the historical-backfill threshold
* — a multi-year Apple Health import shouldn't fire hundreds of
* pushes during initial sync. The flag rides through to the
* dispatcher; the row is still written, the badge still renders, the
* doctor report still picks it up.
* dispatcher; the row is still written and the doctor report still
* picks it up.
*/
silent?: boolean;
/**