@essential-apps/shopify-test-runner 1.0.12 → 1.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/dist/edge/edgeProxy.d.ts.map +1 -1
  2. package/dist/edge/edgeProxy.js +18 -12
  3. package/dist/edge/edgeProxy.js.map +1 -1
  4. package/dist/lib/guestVnc.d.ts +31 -0
  5. package/dist/lib/guestVnc.d.ts.map +1 -0
  6. package/dist/lib/guestVnc.js +111 -0
  7. package/dist/lib/guestVnc.js.map +1 -0
  8. package/dist/probes/runProbe.js +0 -0
  9. package/dist/scripts/addStore.js +0 -0
  10. package/dist/scripts/buildImage.d.ts +3 -0
  11. package/dist/scripts/buildImage.d.ts.map +1 -0
  12. package/dist/scripts/{buildDockerImage.js → buildImage.js} +12 -10
  13. package/dist/scripts/buildImage.js.map +1 -0
  14. package/dist/scripts/captureAuth.js +0 -0
  15. package/dist/scripts/captureContracts.js +0 -0
  16. package/dist/scripts/captureRestContracts.js +0 -0
  17. package/dist/scripts/captureSharedContracts.d.ts +3 -0
  18. package/dist/scripts/captureSharedContracts.d.ts.map +1 -0
  19. package/dist/scripts/captureSharedContracts.js +209 -0
  20. package/dist/scripts/captureSharedContracts.js.map +1 -0
  21. package/dist/scripts/checkOperationCoverage.js +0 -0
  22. package/dist/scripts/cleanupStores.js +0 -0
  23. package/dist/scripts/createStores.js +0 -0
  24. package/dist/scripts/deployAppVersion.js +0 -0
  25. package/dist/scripts/devOnlineBackend.js +0 -0
  26. package/dist/scripts/installApp.js +0 -0
  27. package/dist/scripts/listStores.js +0 -0
  28. package/dist/scripts/runOffline.js +78 -1
  29. package/dist/scripts/runOffline.js.map +1 -1
  30. package/dist/scripts/runOfflineFullTests.js +49 -21
  31. package/dist/scripts/runOfflineFullTests.js.map +1 -1
  32. package/dist/scripts/runTests.js +0 -0
  33. package/dist/scripts/runVm.js +0 -0
  34. package/dist/scripts/runVmAuth.js +0 -0
  35. package/dist/scripts/setupTestDb.js +0 -0
  36. package/dist/scripts/verifyContracts.js +20 -29
  37. package/dist/scripts/verifyContracts.js.map +1 -1
  38. package/dist/scripts/verifyRestContracts.js +17 -30
  39. package/dist/scripts/verifyRestContracts.js.map +1 -1
  40. package/package.json +11 -9
  41. package/src/edge/edgeProxy.ts +19 -12
  42. package/src/lib/guestVnc.ts +147 -0
  43. package/src/scripts/{buildDockerImage.ts → buildImage.ts} +11 -9
  44. package/src/scripts/captureSharedContracts.ts +228 -0
  45. package/src/scripts/runOffline.ts +82 -1
  46. package/src/scripts/runOfflineFullTests.ts +56 -21
  47. package/src/scripts/verifyContracts.ts +22 -38
  48. package/src/scripts/verifyRestContracts.ts +23 -42
  49. package/dist/edge/nodeShim.d.ts +0 -2
  50. package/dist/edge/nodeShim.d.ts.map +0 -1
  51. package/dist/edge/nodeShim.js +0 -217
  52. package/dist/edge/nodeShim.js.map +0 -1
  53. package/dist/scripts/_probeSourceUrl.d.ts +0 -3
  54. package/dist/scripts/_probeSourceUrl.d.ts.map +0 -1
  55. package/dist/scripts/_probeSourceUrl.js +0 -119
  56. package/dist/scripts/_probeSourceUrl.js.map +0 -1
  57. package/dist/scripts/buildDockerImage.d.ts +0 -3
  58. package/dist/scripts/buildDockerImage.d.ts.map +0 -1
  59. package/dist/scripts/buildDockerImage.js.map +0 -1
  60. package/dist/scripts/devE2eBackend.d.ts +0 -3
  61. package/dist/scripts/devE2eBackend.d.ts.map +0 -1
  62. package/dist/scripts/devE2eBackend.js +0 -117
  63. package/dist/scripts/devE2eBackend.js.map +0 -1
  64. package/dist/scripts/runDocker.d.ts +0 -3
  65. package/dist/scripts/runDocker.d.ts.map +0 -1
  66. package/dist/scripts/runDocker.js +0 -88
  67. package/dist/scripts/runDocker.js.map +0 -1
  68. package/dist/scripts/runDockerAuth.d.ts +0 -3
  69. package/dist/scripts/runDockerAuth.d.ts.map +0 -1
  70. package/dist/scripts/runDockerAuth.js +0 -108
  71. package/dist/scripts/runDockerAuth.js.map +0 -1
  72. package/dist/scripts/runDockerOffline.d.ts +0 -3
  73. package/dist/scripts/runDockerOffline.d.ts.map +0 -1
  74. package/dist/scripts/runDockerOffline.js +0 -129
  75. package/dist/scripts/runDockerOffline.js.map +0 -1
  76. package/dist/scripts/runDockerOfflineExplore.d.ts +0 -3
  77. package/dist/scripts/runDockerOfflineExplore.d.ts.map +0 -1
  78. package/dist/scripts/runDockerOfflineExplore.js +0 -116
  79. package/dist/scripts/runDockerOfflineExplore.js.map +0 -1
  80. package/dist/scripts/runIsolatedDockerOffline.d.ts +0 -3
  81. package/dist/scripts/runIsolatedDockerOffline.d.ts.map +0 -1
  82. package/dist/scripts/runIsolatedDockerOffline.js +0 -351
  83. package/dist/scripts/runIsolatedDockerOffline.js.map +0 -1
  84. package/dist/scripts/runOfflineE2e.d.ts +0 -3
  85. package/dist/scripts/runOfflineE2e.d.ts.map +0 -1
  86. package/dist/scripts/runOfflineE2e.js +0 -408
  87. package/dist/scripts/runOfflineE2e.js.map +0 -1
  88. package/dist/scripts/runSupermachine.d.ts +0 -3
  89. package/dist/scripts/runSupermachine.d.ts.map +0 -1
  90. package/dist/scripts/runSupermachine.js +0 -474
  91. package/dist/scripts/runSupermachine.js.map +0 -1
  92. package/dist/scripts/runSupermachineAuth.d.ts +0 -3
  93. package/dist/scripts/runSupermachineAuth.d.ts.map +0 -1
  94. package/dist/scripts/runSupermachineAuth.js +0 -454
  95. package/dist/scripts/runSupermachineAuth.js.map +0 -1
  96. package/dist/vite/offlineConfig.d.ts +0 -34
  97. package/dist/vite/offlineConfig.d.ts.map +0 -1
  98. package/dist/vite/offlineConfig.js +0 -61
  99. package/dist/vite/offlineConfig.js.map +0 -1
  100. package/src/scripts/runDockerAuth.ts +0 -120
@@ -1,408 +0,0 @@
1
- #!/usr/bin/env node
2
- /**
3
- * Run the OFFLINE-FULL e2e suite inside a microVM.
4
- *
5
- * Sibling of `runVm.ts` (which runs the LIVE Shopify suite).
6
- * Both use the same arm64 microVM image; this one drives the offline
7
- * orchestrator (`runOfflineFullTests.js`) instead of the live one
8
- * (`runTests.js`). The runOfflineFullTests script bootstraps the full
9
- * mock stack (Remix backend + MSW Admin + storefront + mock admin
10
- * shell + per-run Postgres DB) entirely inside the VM — no Shopify
11
- * round-trips, no Cloudflare, no auth.
12
- *
13
- * Architecture (matches the live runner where the shape overlaps):
14
- *
15
- * - Same image (`essential-apps/shopify-test-vm:latest`)
16
- * as the live runner — one image to bake, both runners restore
17
- * from the same snapshot family.
18
- * - Bind mounts (virtio-fs DAX):
19
- * - consuming app repo → /workspace
20
- * - linux node_modules cache → /workspace/node_modules
21
- * - Postgres autostart + /etc/hosts patch + npm install folded
22
- * into the warmup callback. Warm restores skip all of that.
23
- * - `runOfflineFullTests.js` spawned inside; its in-VM Vite +
24
- * Playwright + mocks all dial localhost.
25
- *
26
- * Why a host build of `build/server/index.js` is required:
27
- * the in-VM Vite build is markedly slower than the host one (~5 min
28
- * vs ~6 s) and hits a virtio-fs perf cliff during the Rollup small-
29
- * file emission phase. Building on the host + skipping the in-VM
30
- * build with TEST_OFFLINE_SKIP_BUILD=true is the supported path.
31
- * runOfflineFullTests.js still spins up Vite for non-build needs.
32
- *
33
- * Override env vars (mirrors runVm where applicable; same
34
- * TEST_ONLINE_VM_* knobs):
35
- * TEST_ONLINE_VM_IMAGE / TEST_ONLINE_VM_IMAGE_SOURCE
36
- * TEST_ONLINE_VM_IMAGE_LAYOUT_PATH
37
- * TEST_ONLINE_VM_MEMORY_MIB Default: 8192.
38
- * TEST_ONLINE_VM_VCPUS Default: 4.
39
- * TEST_LINUX_NODE_MODULES Default: ~/.cache/${appName}-e2e/node_modules
40
- * TEST_ONLINE_VM_TIMEOUT_MS Default: 10 min.
41
- * TEST_OFFLINE_EXTENSIONS_JSON forwarded to runOfflineFullTests.
42
- * TEST_OFFLINE_POST_PURCHASE_EXT forwarded.
43
- * LIQUID_CONTRACTS_CAPTURE set to 'true' to regenerate
44
- * tests/test-offline/contracts/liquid/*.html
45
- * in full-suite context. See
46
- * tests/README.md.
47
- * PLAYWRIGHT_GREP forwarded as Playwright --grep,
48
- * e.g. PLAYWRIGHT_GREP='cart flow'
49
- */
50
- import { createHash } from 'node:crypto';
51
- import { existsSync, mkdirSync, readFileSync } from 'node:fs';
52
- import { homedir } from 'node:os';
53
- import { resolve } from 'node:path';
54
- import { pickApp, prepareOciArchive } from '@essential-apps/shopify-test-core';
55
- const repoRoot = process.cwd();
56
- function readAppName() {
57
- const pkgPath = resolve(repoRoot, 'package.json');
58
- if (!existsSync(pkgPath)) {
59
- throw new Error(`No package.json at ${pkgPath}. Run this from the consuming app's repo root.`);
60
- }
61
- const pkg = JSON.parse(readFileSync(pkgPath, 'utf8'));
62
- if (!pkg.name) {
63
- throw new Error(`package.json at ${pkgPath} has no \`name\` field.`);
64
- }
65
- return pkg.name.replace(/^@[^/]+\//, '');
66
- }
67
- /**
68
- * Resolve the VM image source the same way the conformance
69
- * runner does. Duplicated here intentionally — extracting into a
70
- * shared helper would create a runner→conformance dep cycle (runner
71
- * is allowed to depend on conformance, but in practice this is the
72
- * single use-site and the indirection isn't worth a new dep).
73
- */
74
- async function imageSourceOptions() {
75
- const mode = process.env['TEST_ONLINE_VM_IMAGE_SOURCE'] ?? 'oci-archive';
76
- if (mode === 'registry')
77
- return {};
78
- const ref = process.env['TEST_ONLINE_VM_IMAGE'] ??
79
- 'essential-apps/shopify-test-vm:latest';
80
- if (mode === 'oci-archive') {
81
- const prep = await prepareOciArchive(ref);
82
- if (prep.freshlySaved) {
83
- console.error(`[runOfflineE2e] saved ${ref} → ${prep.archivePath} (${(prep.sizeBytes / 1024 / 1024).toFixed(1)} MB)`);
84
- }
85
- return { source: 'oci-archive', sourcePath: prep.archivePath };
86
- }
87
- if (mode === 'oci-layout') {
88
- const sourcePath = process.env['TEST_ONLINE_VM_IMAGE_LAYOUT_PATH'];
89
- if (!sourcePath) {
90
- throw new Error(`TEST_ONLINE_VM_IMAGE_SOURCE=oci-layout requires TEST_ONLINE_VM_IMAGE_LAYOUT_PATH`);
91
- }
92
- return { source: 'oci-layout', sourcePath };
93
- }
94
- throw new Error(`TEST_ONLINE_VM_IMAGE_SOURCE=${mode} not recognised. Valid: oci-archive | oci-layout | registry`);
95
- }
96
- async function main() {
97
- const appName = readAppName();
98
- const linuxModules = process.env['TEST_LINUX_NODE_MODULES'] ??
99
- resolve(homedir(), `.cache/${appName}-e2e/node_modules`);
100
- mkdirSync(linuxModules, { recursive: true });
101
- // Tarball-manifest written by `scripts/pack-into.sh` — a hash list
102
- // of the vendored @essential-apps/* tarballs. Passed as an
103
- // `extraFile` so its bytes fold into the snapshot's bake input-hash:
104
- // any tarball change (= someone ran pack-into.sh) changes the
105
- // manifest, which invalidates the snapshot, which re-runs warmup,
106
- // which reinstalls. This is what makes a tarball refresh "just work"
107
- // WITHOUT a manual warmupTag bump or a `rm -rf ~/.cache/<app>-e2e`.
108
- //
109
- // Before this, the only snapshot key was the static `warmupTag`
110
- // string, so a tarball refresh left a stale snapshot + a stale
111
- // bind-mounted node_modules cache serving old code — the classic
112
- // "I repacked but the test still runs the old build" footgun.
113
- // (Mirrors the live runner runVm.ts, which already does this.)
114
- const tarballManifest = resolve(repoRoot, 'vendor/essential-apps-shopify-test/.tarball-manifest');
115
- const tarballManifestExists = existsSync(tarballManifest);
116
- // Fold a hash of the manifest into the warmupTag. The `extraFiles`
117
- // approach alone (below) does NOT reliably invalidate the snapshot
118
- // in this VM-runtime version — observed: manifest changed but bake
119
- // was still a 0.0s warm restore. The warmupTag, by contrast,
120
- // DEFINITIVELY keys the snapshot (a tag bump always rebakes). So we
121
- // hash the manifest (itself a sha256 list of the vendored tarballs)
122
- // into the tag: any tarball change → manifest change → tag change →
123
- // rebake → warmup reinstalls. The leading `v12` is the WARMUP-SCRIPT
124
- // version — bump it only when changing the warmup steps below
125
- // (perms/hosts/install), not for tarball refreshes.
126
- const manifestHash = tarballManifestExists
127
- ? createHash('sha256').update(readFileSync(tarballManifest)).digest('hex').slice(0, 12)
128
- : 'no-manifest';
129
- const warmupTag = `offline-e2e-v12-${manifestHash}`;
130
- // Dynamic import — @supermachine/core is heavy and only needed
131
- // when actually running tests, not for `--help` etc.
132
- const { Image } = await import('@supermachine/core');
133
- const imageOpts = await imageSourceOptions();
134
- console.error(`[runOfflineE2e] baking image… (warmupTag=${warmupTag})`);
135
- const tBake = performance.now();
136
- const image = await Image.build({
137
- ref: process.env['TEST_ONLINE_VM_IMAGE'] ??
138
- 'essential-apps/shopify-test-vm:latest',
139
- memoryMib: Number(process.env['TEST_ONLINE_VM_MEMORY_MIB'] ?? 8192),
140
- vcpus: Number(process.env['TEST_ONLINE_VM_VCPUS'] ?? 4),
141
- cmd: ['sleep', 'infinity'],
142
- mounts: [
143
- // VM runtime 0.7.28+ requires explicit guestPath and
144
- // auto-mounts at boot before warmup fires.
145
- { hostPath: repoRoot, guestTag: 'workspace', guestPath: '/workspace' },
146
- { hostPath: linuxModules, guestTag: 'lmod', guestPath: '/workspace/node_modules' },
147
- ],
148
- extraFiles: tarballManifestExists
149
- ? [
150
- // Belt-and-suspenders alongside the manifest-hashed
151
- // warmupTag (the tag is what actually drives invalidation;
152
- // see warmupTag note above). Harmless if the runtime ignores
153
- // it; matches the live runner runVm.ts.
154
- { hostPath: tarballManifest, guestPath: '/etc/.shopify-test-tarball-manifest' },
155
- ]
156
- : [],
157
- // Snapshot key. `warmupTag` is computed from the tarball-manifest
158
- // hash (see above), so a tarball refresh auto-rebakes WITHOUT a
159
- // manual bump or a `rm -rf ~/.cache/<app>-e2e`. Warmup runs ONCE
160
- // per bake; warm acquires skip it.
161
- warmupTag,
162
- // @ts-expect-error — @supermachine/core's BuildOptions type
163
- // doesn't declare `warmup`, but the runtime accepts it. Tracked
164
- // upstream; fix-or-augment when the types catch up.
165
- warmup: async (vm) => {
166
- const r = await vm.exec({
167
- argv: ['sh', '-c', `
168
- set -e
169
- # VM runtime 0.7.28+ auto-mounts declared mounts/volumes
170
- # at boot before warmup fires — no manual mount needed.
171
- echo "--- repair perms for postgres ---"
172
- chown -R postgres:postgres /var/lib/postgresql/data
173
- chmod 700 /var/lib/postgresql/data
174
- mkdir -p /var/run/postgresql
175
- chown postgres:postgres /var/run/postgresql
176
- chmod 775 /var/run/postgresql
177
-
178
- echo "--- npm install (fresh per rebake) ---"
179
- # Warmup runs EXACTLY when the snapshot rebakes — which now
180
- # happens only when the tarball-manifest extraFile changes
181
- # (pack-into.sh) or the warmupTag bumps. Either way we want a
182
- # clean install, so wipe the bind-mounted cache first; npm
183
- # can't reuse a stale tarball that way.
184
- #
185
- # NB: this is a DEDICATED cache dir (~/.cache/<app>-e2e/
186
- # node_modules), NOT the repo's node_modules, so the rm-rf is
187
- # safe. Replaces the old "skip if .package-lock.json exists"
188
- # check, which left stale code in the cache across tarball
189
- # refreshes (the bind mount served old bytes because warmup
190
- # never re-ran the install).
191
- cd /workspace
192
- rm -rf node_modules/* node_modules/.[!.]* 2>/dev/null || true
193
- npm install --legacy-peer-deps --engine-strict=false 2>&1 | tail -10
194
-
195
- echo "--- patch /etc/hosts for localhost ---"
196
- if ! grep -q "^127.0.0.1.*localhost" /etc/hosts; then
197
- echo "127.0.0.1 localhost" >> /etc/hosts
198
- echo "::1 localhost" >> /etc/hosts
199
- fi
200
-
201
- echo "--- warmup done ---"
202
- `],
203
- timeoutMs: 15 * 60 * 1000,
204
- });
205
- if (r.exitCode !== 0) {
206
- throw new Error(`warmup failed (exit ${r.exitCode}): ${r.stderr.toString().slice(-2000)}\n${r.stdout.toString().slice(-2000)}`);
207
- }
208
- },
209
- ...imageOpts,
210
- });
211
- console.error(`[runOfflineE2e] bake: ${((performance.now() - tBake) / 1000).toFixed(1)} s`);
212
- const pool = await image.pool({ min: 1, max: 1, restoreOnRelease: false });
213
- const vm = await pool.acquire();
214
- try {
215
- // Postgres startup — fast because warmup already chowned the data dir.
216
- const tPg = performance.now();
217
- const pgR = await vm.exec({
218
- argv: ['sh', '-c', `
219
- export PGDATA=/var/lib/postgresql/data
220
- export PG_BIN=/usr/lib/postgresql/14/bin
221
- if su postgres -c "\${PG_BIN}/pg_ctl -D \${PGDATA} status" >/dev/null 2>&1; then echo running; exit 0; fi
222
- if [ -z "$(ls -A \${PGDATA} 2>/dev/null)" ]; then su postgres -c "\${PG_BIN}/initdb -D \${PGDATA} -A trust" >/dev/null; fi
223
- su postgres -c "\${PG_BIN}/pg_ctl -D \${PGDATA} -l /tmp/pg.log -o '-h 127.0.0.1 -p 5432' start" >/dev/null
224
- for _ in $(seq 1 50); do
225
- if su postgres -c "\${PG_BIN}/pg_isready -h 127.0.0.1 -p 5432" >/dev/null 2>&1; then
226
- # Create 'root' superuser to match the libkrun image entrypoint
227
- # — runTests.js connects as 'root'.
228
- su postgres -c "\${PG_BIN}/createuser -h 127.0.0.1 -p 5432 -s root" 2>&1 | grep -v 'already exists' || true
229
- exit 0
230
- fi
231
- sleep 0.1
232
- done
233
- cat /tmp/pg.log
234
- exit 1
235
- `],
236
- timeoutMs: 30_000,
237
- });
238
- if (pgR.exitCode !== 0) {
239
- console.error('[runOfflineE2e] postgres start failed:', pgR.stderr.toString());
240
- process.exit(1);
241
- }
242
- console.error(`[runOfflineE2e] postgres: ${((performance.now() - tPg) / 1000).toFixed(2)} s`);
243
- // Forward a curated env subset. Mostly the same as the live
244
- // runner, plus the offline-specific extension list + post-
245
- // purchase host + the SKIP_BUILD escape hatch the host-build
246
- // path requires + LIQUID_CONTRACTS_CAPTURE for regenerating
247
- // the stored Liquid snapshots.
248
- const forwardEnv = {};
249
- for (const k of [
250
- 'TEST_VISIBLE',
251
- 'TEST_WORKERS',
252
- 'TEST_PRESERVE_DB',
253
- 'TEST_OFFLINE_STRICT_GRAPHQL',
254
- 'TEST_OFFLINE_EXTENSIONS_JSON',
255
- 'TEST_OFFLINE_POST_PURCHASE_EXT',
256
- 'LIQUID_CONTRACTS_CAPTURE',
257
- // Playwright reads this natively to update visual-regression
258
- // PNG baselines (`all` | `missing` | `none`). Forward so
259
- // teammates can run `PLAYWRIGHT_UPDATE_SNAPSHOTS=all npm run
260
- // test:offline` after intentional UI changes.
261
- 'PLAYWRIGHT_UPDATE_SNAPSHOTS',
262
- 'CI',
263
- 'DEBUG',
264
- ]) {
265
- const v = process.env[k];
266
- if (v !== undefined)
267
- forwardEnv[k] = v;
268
- }
269
- forwardEnv['TEST_IN_CONTAINER'] = 'true';
270
- // Auto-wire the consuming app's theme app extensions into the
271
- // storefront mock. Without this, the orchestrator's `loadExtensions`
272
- // returns [] and no app-embed Liquid gets injected into rendered
273
- // pages — symptoms: widget tests time out waiting for
274
- // `<essential-upsell-app-embed>` to attach or
275
- // `[data-essential-upsell-funnel-id]` to portal.
276
- //
277
- // Source of truth is `tests/test-online/.apps.json` — same file the
278
- // online tier reads (one app registry, shared across tiers). Each
279
- // extension entry needs a host-side `rootDir`; we translate it to
280
- // the VM-side `/workspace/<rel>` path so the orchestrator sees the
281
- // extension at the same logical location it lives in the repo.
282
- //
283
- // Honour a pre-set `TEST_OFFLINE_EXTENSIONS_JSON` (e.g. the user
284
- // wants a custom mix) — only auto-populate when the env var is
285
- // missing. Same pattern for `TEST_OFFLINE_POST_PURCHASE_EXT`.
286
- if (!forwardEnv['TEST_OFFLINE_EXTENSIONS_JSON']) {
287
- try {
288
- const app = pickApp();
289
- if (app.extensions && app.extensions.length > 0) {
290
- const vmExtensions = app.extensions
291
- .filter((e) => e.rootDir)
292
- .map((e) => ({
293
- name: e.name,
294
- // rootDir in .apps.json is relative to the consumer repo
295
- // (e.g. `app_extensions/upsells`). Inside the VM, the
296
- // repo is bind-mounted at `/workspace`.
297
- rootDir: `/workspace/${e.rootDir.replace(/^\.?\//, '')}`,
298
- }));
299
- if (vmExtensions.length > 0) {
300
- forwardEnv['TEST_OFFLINE_EXTENSIONS_JSON'] = JSON.stringify(vmExtensions);
301
- }
302
- // Post-purchase bundle (separate env — orchestrator loads it
303
- // via a different code path from theme app extensions).
304
- if (!forwardEnv['TEST_OFFLINE_POST_PURCHASE_EXT']) {
305
- const postPurchase = app.extensions.find((e) => e.postPurchaseBundle);
306
- if (postPurchase?.postPurchaseBundle) {
307
- forwardEnv['TEST_OFFLINE_POST_PURCHASE_EXT'] = `/workspace/${postPurchase.postPurchaseBundle.replace(/^\.?\//, '')}`;
308
- }
309
- }
310
- }
311
- }
312
- catch (err) {
313
- // .apps.json missing or malformed — skip auto-wiring rather than
314
- // crash. Tests that don't depend on extensions still run.
315
- console.error(`[runOfflineE2e] couldn't auto-load extensions from .apps.json: ${err.message}`);
316
- }
317
- }
318
- // The host-built bundle in build/server/index.js was generated
319
- // with the host's Prisma client. Skip the in-VM rebuild — see
320
- // the runOfflineFullTests source for the full picture. The
321
- // host build must exist and be fresh; `npm run build` in the
322
- // consuming app with TEST_OFFLINE=true NODE_ENV=production
323
- // before invoking this script.
324
- forwardEnv['TEST_OFFLINE_SKIP_BUILD'] = 'true';
325
- // Pin Prisma to the linux-arm64 query engine that lives in
326
- // LMOD's node_modules/.prisma/client/. The bundled client's
327
- // built-in resolver gets confused by the host-vs-guest engine
328
- // mismatch unless we tell it exactly which .so.node to dlopen.
329
- forwardEnv['PRISMA_QUERY_ENGINE_LIBRARY'] =
330
- '/workspace/node_modules/.prisma/client/libquery_engine-linux-arm64-openssl-3.0.x.so.node';
331
- // Optional --grep forwarding for fast iteration on a single
332
- // scenario or spec without writing a one-off bench script.
333
- const grep = process.env['PLAYWRIGHT_GREP'];
334
- const grepArg = grep ? `--grep ${JSON.stringify(grep)}` : '';
335
- // Spawn the test runner. Streaming stdout/stderr via spawn so
336
- // the user sees Playwright output as it lands rather than at end.
337
- console.error('[runOfflineE2e] launching runOfflineFullTests.js…');
338
- const tTests = performance.now();
339
- const testProc = await vm.spawn({
340
- argv: ['sh', '-c', `
341
- cd /workspace
342
- # node_modules/.bin on PATH so test code can shell out to
343
- # local CLIs (shopify, prisma, playwright).
344
- export PATH=/workspace/node_modules/.bin:$PATH
345
- node --env-file=.env.test node_modules/@essential-apps/shopify-test-runner/dist/scripts/runOfflineFullTests.js ${grepArg}
346
- `],
347
- env: forwardEnv,
348
- });
349
- // Stream + collect output. Hard 10-min cap by default, with a
350
- // no-output stall guard for hung processes.
351
- //
352
- // The stall guard has to outlast legitimate cold-start silence:
353
- // - edge proxy bind (instant)
354
- // - prisma migrate deploy (~5-15 s cold)
355
- // - Remix backend boot via remix-serve (~10-30 s cold)
356
- // - Playwright spawning chromium (~10-30 s cold first time)
357
- // - testDir discovery + worker boot
358
- // Cumulative cold-start silence can reach ~60-90 s before any test
359
- // produces stdout. Default 180 s lives comfortably outside that
360
- // window. Override via env if a test legitimately needs more.
361
- const maxMs = Number(process.env['TEST_ONLINE_VM_TIMEOUT_MS'] ?? 10 * 60 * 1000);
362
- const stallMs = Number(process.env['TEST_OFFLINE_STALL_MS'] ?? 180_000);
363
- const start = Date.now();
364
- let lastByteAt = Date.now();
365
- while (true) {
366
- const out = await testProc.readStdout(64 * 1024);
367
- const now = Date.now();
368
- if (out.length === 0) {
369
- if (now - start > maxMs) {
370
- console.error(`\n[runOfflineE2e] HARD TIMEOUT ${maxMs / 1000}s — killing`);
371
- await testProc.signal(15).catch(() => { });
372
- break;
373
- }
374
- if (now - lastByteAt > stallMs) {
375
- console.error(`\n[runOfflineE2e] no output for ${stallMs / 1000}s — killing`);
376
- await testProc.signal(15).catch(() => { });
377
- break;
378
- }
379
- await new Promise((r) => setTimeout(r, 200));
380
- continue;
381
- }
382
- lastByteAt = now;
383
- process.stdout.write(out);
384
- // Playwright summary lines look like " 17 passed (45.6s)" or
385
- // " 3 failed". Once we see one, drain the tail and break.
386
- if (/\b\d+ (passed|failed)\b/.test(out.toString())) {
387
- await new Promise((r) => setTimeout(r, 500));
388
- const tail = await testProc.readStdout(64 * 1024);
389
- if (tail.length > 0)
390
- process.stdout.write(tail);
391
- break;
392
- }
393
- }
394
- const wait = await testProc.wait();
395
- console.error(`[runOfflineE2e] tests: ${((performance.now() - tTests) / 1000).toFixed(1)} s`);
396
- console.error(`[runOfflineE2e] grand: ${((performance.now() - tBake) / 1000).toFixed(1)} s`);
397
- process.exit(wait.exitCode ?? 0);
398
- }
399
- finally {
400
- await vm.release().catch(() => { });
401
- await pool.shutdown().catch(() => { });
402
- }
403
- }
404
- main().catch((err) => {
405
- console.error(err);
406
- process.exit(1);
407
- });
408
- //# sourceMappingURL=runOfflineE2e.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"runOfflineE2e.js","sourceRoot":"","sources":["../../src/scripts/runOfflineE2e.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAE/E,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;AAM/B,SAAS,WAAW;IAClB,MAAM,OAAO,GAAG,OAAO,CAAC,QAAQ,EAAE,cAAc,CAAC,CAAC;IAClD,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC;QACzB,MAAM,IAAI,KAAK,CACb,sBAAsB,OAAO,gDAAgD,CAC9E,CAAC;IACJ,CAAC;IACD,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,OAAO,EAAE,MAAM,CAAC,CAAgB,CAAC;IACrE,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;QACd,MAAM,IAAI,KAAK,CAAC,mBAAmB,OAAO,yBAAyB,CAAC,CAAC;IACvE,CAAC;IACD,OAAO,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;AAC3C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GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;QAC9F,OAAO,CAAC,KAAK,CAAC,0BAA0B,CAAC,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;QAC7F,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,CAAC,CAAC,CAAC;IACnC,CAAC;YAAS,CAAC;QACT,MAAM,EAAE,CAAC,OAAO,EAAE,CAAC,KAAK,CAAC,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC;QACnC,MAAM,IAAI,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC;IACxC,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE;IACnB,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACnB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
@@ -1,3 +0,0 @@
1
- #!/usr/bin/env node
2
- export {};
3
- //# sourceMappingURL=runSupermachine.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"runSupermachine.d.ts","sourceRoot":"","sources":["../../src/scripts/runSupermachine.ts"],"names":[],"mappings":""}