release acceptance matrix: tools/acceptance.ts runs every user-facing command from the packed npm tarball (npx --package=<tgz> on Node 20 / 22, bun x --bun after bun add <tgz>) in fresh temp folders with a fresh HOME, real piped stdin (n, EOF) and per-cell fake stores over HTTP (STOREBOUND_STORE_MOCK, loopback only); a cell passes only with the expected exit code and no crash text; report -> markdown matrix. Prompts go through stdinIsTTY (STOREBOUND_ASSUME_TTY drives them with piped stdin), STOREBOUND_DESKTOP_APP=none for the install prompt on a machine with the app. release.yml: required acceptance job matrix (Linux + Windows x node20/node22/bun) and report, the matrix attached to the release; ci.yml: the quick subset on Linux and Windows. Scan fixtures for React Native and Expo

This commit is contained in:
CRTkafa 2026-10-14 08:29:26 +08:00
parent ae681e3ecd
commit f58e192001
26 changed files with 926 additions and 15 deletions

View file

@ -19,6 +19,7 @@ import type { Ctx } from '../lib/ctx';
import { confirm, need } from '../lib/ctx';
import { done, log, printJson, step, warn } from '../lib/log';
import { playClient } from './client';
import { stdinIsTTY } from '../lib/tty';
export function readPlayCopy(ctx: Ctx) {
const { config, resolve } = ctx.loaded;
@ -139,7 +140,7 @@ export async function run(ctx: Ctx): Promise<void> {
else for (const line of playPlanLines(p)) console.log(line);
if (dry) { done('play', `dry run: ${p.changes ? `${p.changes} change(s)` : 'nothing to change'}; read-only, nothing written`); return; }
if (!p.changes) { done('play', 'listing already up to date'); return; }
if (process.stdin.isTTY && !(await confirm(ctx, `Apply these ${p.changes} change(s) to Google Play (one edit, committed)?`))) { warn('play', 'nothing written'); return; }
if (stdinIsTTY() && !(await confirm(ctx, `Apply these ${p.changes} change(s) to Google Play (one edit, committed)?`))) { warn('play', 'nothing written'); return; }
// The edit compares again with what it holds (a Console save or another run since the plan): only differing details
// and languages are PUT; nothing left to change = the edit is deleted, not committed. Commit only after every PUT worked.
let sent = 0;

View file

@ -26,6 +26,7 @@ import {
import { subscriptionCsv } from '../apple/subscriptions';
import { createOnce } from '../lib/upsert';
import { playClient, type PlayClient } from './client';
import { stdinIsTTY } from '../lib/tty';
/** GET of one Play resource, null on 404. */
export async function getOrNull<T>(play: PlayClient, url: string): Promise<T | null> {
@ -88,7 +89,7 @@ export async function run(ctx: Ctx): Promise<void> {
const yes = ctx.args.has('yes');
const priced = todo.filter(w => w.diff.basePlan === 'changed' && w.diff.priceChanges.length);
let liveOk: boolean;
if (process.stdin.isTTY && !yes && process.env.STOREBOUND_SERVE !== '1') {
if (stdinIsTTY() && !yes && process.env.STOREBOUND_SERVE !== '1') {
if (!(await confirm(ctx, `Write ${todo.length} subscription(s) to Google Play? Activated base plans and offers can be bought as soon as the app is published; price changes apply to new subscribers.`))) return;
liveOk = true;
} else {