The run rebuilds the module runtimes its beds stock
A per-module bed stocks mesh-runtime-<module>:development from the workstation's image store, built by hand by a script the suite never called; six were two weeks older than the manifests they served. For the beds named, every runtime their scenarios stock is compared against the module's source and the tool runtime and SDK it is built on, and rebuilt where older, missing or uncommitted; a failed build stops the suite (novox/hq 04-ISSUES/075).
This commit is contained in:
+10
-3
@@ -16,6 +16,7 @@
|
||||
|
||||
import { spawnSync } from "node:child_process";
|
||||
import { repositories } from "./repos.ts";
|
||||
import { plannedRuntimes } from "./runtimes.ts";
|
||||
|
||||
export interface Build {
|
||||
/** What it produces, for the log. */
|
||||
@@ -112,10 +113,16 @@ export function carriedImage(env: NodeJS.ProcessEnv = process.env): string {
|
||||
return env["MESH_LAB_CARRIED_IMAGE"] ?? "mesh-builder:development";
|
||||
}
|
||||
|
||||
/** rebuild runs the plan, and throws on the first failure rather than testing a stale artifact. */
|
||||
export function rebuild(env: NodeJS.ProcessEnv = process.env): string[] {
|
||||
/**
|
||||
* rebuild runs the plan, and throws on the first failure rather than testing a stale artifact.
|
||||
*
|
||||
* The plan is what the run was pointed at, plus the module runtimes the named beds stock where
|
||||
* those are older than their source (novox/hq 04-ISSUES/075) — so a bed never again passes against
|
||||
* a runtime built two weeks before the manifest it serves.
|
||||
*/
|
||||
export function rebuild(env: NodeJS.ProcessEnv = process.env, testFiles: string[] = []): string[] {
|
||||
const built: string[] = [];
|
||||
for (const build of planned(env)) {
|
||||
for (const build of [...planned(env), ...plannedRuntimes(testFiles, env)]) {
|
||||
const [command, ...args] = build.argv;
|
||||
const ran = spawnSync(command!, args, {
|
||||
cwd: build.in,
|
||||
|
||||
Reference in New Issue
Block a user