新增 OPFS session 独立 browser workflow gate
This commit is contained in:
@@ -138,7 +138,7 @@
|
||||
"workflow overview release artifact validation API name",
|
||||
);
|
||||
assertEqual(releaseArtifactValidation.ready, true, "workflow overview release artifact validation readiness");
|
||||
assertEqual(releaseArtifactValidation.gateCount, 10, "workflow overview release artifact validation gates");
|
||||
assertEqual(releaseArtifactValidation.gateCount, 11, "workflow overview release artifact validation gates");
|
||||
assertEqual(
|
||||
releaseArtifactValidationSummary.statusLine,
|
||||
"Ready: Artifact evidence complete",
|
||||
|
||||
203
wasm-port/tests/browser/opfs_session_workflow_smoke.html
Normal file
203
wasm-port/tests/browser/opfs_session_workflow_smoke.html
Normal file
@@ -0,0 +1,203 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>LinuxCNC OPFS Session Workflow Smoke</title>
|
||||
</head>
|
||||
<body>
|
||||
<pre id="status">running</pre>
|
||||
<script type="module">
|
||||
import {
|
||||
createLinuxCncIniSdk,
|
||||
createLinuxCncInterpSdk,
|
||||
createMachineSessionPersistenceSummary,
|
||||
gcodeProgramPath,
|
||||
loadGcodeProgram,
|
||||
loadMachineSessionFromOpfs,
|
||||
loadMachineSessionSnapshot,
|
||||
loadMachineTextFiles,
|
||||
machineFilePaths,
|
||||
readMachineSessionReadiness,
|
||||
saveGcodeProgram,
|
||||
saveMachineSessionSnapshot,
|
||||
saveMachineTextFiles,
|
||||
} from "../../runtime/sdk/src/index.js";
|
||||
|
||||
const status = document.getElementById("status");
|
||||
|
||||
function assertEqual(actual, expected, label) {
|
||||
if (actual !== expected) {
|
||||
throw new Error(`${label}: expected ${expected}, got ${actual}`);
|
||||
}
|
||||
}
|
||||
|
||||
function assertIncludes(values, expected, label) {
|
||||
if (!values.includes(expected)) {
|
||||
throw new Error(`${label}: expected ${expected} in ${values.join(", ")}`);
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
const machineId = "browser-opfs-session-gate";
|
||||
const sessionId = "browser-opfs-session-gate-session";
|
||||
const snapshotFilename = "browser-opfs-session-gate.json";
|
||||
const gcodeFilename = "browser-opfs-session-gate.ngc";
|
||||
const gcodeOpfsPath = gcodeProgramPath(gcodeFilename);
|
||||
const paths = machineFilePaths(machineId);
|
||||
const iniText = `[EMC]
|
||||
MACHINE = browser-opfs-session-gate
|
||||
|
||||
[TRAJ]
|
||||
LINEAR_UNITS = mm
|
||||
COORDINATES = X Y Z
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = linuxcnc.var
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
`;
|
||||
const parameterText = [
|
||||
"5161 0.0",
|
||||
"5162 0.0",
|
||||
"5220 1",
|
||||
"5221 0.0",
|
||||
"5399 0.0",
|
||||
"",
|
||||
].join("\n");
|
||||
const toolTableText = "T1 P1 Z0.0 D0.125 ;browser opfs session gate\n";
|
||||
const gcodeText = "G0 X0 Y0\nG1 X1 Y1 F20\nM2\n";
|
||||
|
||||
const initialReadiness = await readMachineSessionReadiness(machineId, {
|
||||
gcodeFilename,
|
||||
sessionId,
|
||||
snapshotFilename,
|
||||
});
|
||||
assertEqual(initialReadiness.ready, false, "initial readiness");
|
||||
assertIncludes(initialReadiness.missing, "ini", "initial missing INI");
|
||||
assertIncludes(initialReadiness.missing, "parameters", "initial missing parameters");
|
||||
assertIncludes(initialReadiness.missing, "toolTable", "initial missing tool table");
|
||||
assertIncludes(initialReadiness.missing, "gcode", "initial missing G-code");
|
||||
assertIncludes(initialReadiness.missing, "snapshot", "initial missing snapshot");
|
||||
|
||||
await saveMachineTextFiles(machineId, {
|
||||
ini: iniText,
|
||||
parameters: parameterText,
|
||||
toolTable: toolTableText,
|
||||
});
|
||||
await saveGcodeProgram(gcodeFilename, gcodeText);
|
||||
const snapshot = await saveMachineSessionSnapshot(sessionId, machineId, {
|
||||
filename: snapshotFilename,
|
||||
gcodeFilename,
|
||||
createdAt: "2026-06-16T00:00:00.000Z",
|
||||
metadata: {
|
||||
workflow: "opfs-session-workflow-browser-gate",
|
||||
defaultGcodeOpfsPath: gcodeOpfsPath,
|
||||
snapshotLabel: `${sessionId}/${snapshotFilename}`,
|
||||
},
|
||||
});
|
||||
|
||||
const files = await loadMachineTextFiles(machineId);
|
||||
assertEqual(files.ini, iniText, "loaded INI text");
|
||||
assertEqual(files.parameters, parameterText, "loaded parameter text");
|
||||
assertEqual(files.toolTable, toolTableText, "loaded tool table text");
|
||||
assertEqual(await loadGcodeProgram(gcodeFilename), gcodeText, "loaded G-code text");
|
||||
assertEqual(snapshot.payload.files.ini, paths.ini, "snapshot INI path");
|
||||
assertEqual(snapshot.payload.files.parameters, paths.parameters, "snapshot parameter path");
|
||||
assertEqual(snapshot.payload.files.toolTable, paths.toolTable, "snapshot tool table path");
|
||||
assertEqual(snapshot.payload.files.gcode, gcodeOpfsPath, "snapshot G-code path");
|
||||
assertEqual(
|
||||
(await loadMachineSessionSnapshot(sessionId, machineId, { filename: snapshotFilename }))
|
||||
.metadata.workflow,
|
||||
"opfs-session-workflow-browser-gate",
|
||||
"loaded snapshot workflow metadata",
|
||||
);
|
||||
|
||||
const readyReadiness = await readMachineSessionReadiness(machineId, {
|
||||
gcodeFilename,
|
||||
sessionId,
|
||||
snapshotFilename,
|
||||
});
|
||||
assertEqual(readyReadiness.ready, true, "ready readiness");
|
||||
assertEqual(readyReadiness.phase, "ready", "ready phase");
|
||||
assertEqual(readyReadiness.missing.length, 0, "ready missing count");
|
||||
assertEqual(readyReadiness.checks.length, 4, "ready file check count");
|
||||
assertEqual(readyReadiness.snapshotCheck.ok, true, "ready snapshot check");
|
||||
|
||||
const iniSdk = await createLinuxCncIniSdk();
|
||||
const interpSdk = await createLinuxCncInterpSdk();
|
||||
const loadedSession = await loadMachineSessionFromOpfs(interpSdk, machineId, {
|
||||
iniSdk,
|
||||
iniWasmPath: "/work/opfs-session-workflow.ini",
|
||||
parameterWasmPath: "/work/opfs-session-workflow.var",
|
||||
toolTableWasmPath: "/work/opfs-session-workflow.tbl",
|
||||
});
|
||||
assertEqual(loadedSession.machineId, machineId, "loaded session machine");
|
||||
assertEqual(loadedSession.ini.opfsPath, paths.ini, "loaded session INI OPFS path");
|
||||
assertEqual(loadedSession.ini.wasmPath, "/work/opfs-session-workflow.ini", "loaded session INI WASM path");
|
||||
assertEqual(loadedSession.parameters.opfsPath, paths.parameters, "loaded session parameter OPFS path");
|
||||
assertEqual(loadedSession.parameters.wasmPath, "/work/opfs-session-workflow.var", "loaded session parameter WASM path");
|
||||
assertEqual(loadedSession.toolTable.opfsPath, paths.toolTable, "loaded session tool table OPFS path");
|
||||
assertEqual(loadedSession.toolTable.wasmPath, "/work/opfs-session-workflow.tbl", "loaded session tool table WASM path");
|
||||
|
||||
const persistenceSummary = createMachineSessionPersistenceSummary({
|
||||
state: {
|
||||
badges: { opfs: "OPFS: ready" },
|
||||
machineFiles: {
|
||||
iniOpfsPath: paths.ini,
|
||||
parameterOpfsPath: paths.parameters,
|
||||
toolTableOpfsPath: paths.toolTable,
|
||||
gcodeOpfsPath,
|
||||
},
|
||||
sessionSnapshot: {
|
||||
snapshotLabel: `${sessionId}/${snapshotFilename}`,
|
||||
iniOpfsPath: paths.ini,
|
||||
parameterOpfsPath: paths.parameters,
|
||||
toolTableOpfsPath: paths.toolTable,
|
||||
gcodeOpfsPath,
|
||||
workflow: "opfs-session-workflow-browser-gate",
|
||||
},
|
||||
sessionReadiness: readyReadiness,
|
||||
sessionLoad: {
|
||||
iniWasmPath: loadedSession.ini.wasmPath,
|
||||
parameterWasmPath: loadedSession.parameters.wasmPath,
|
||||
toolTableWasmPath: loadedSession.toolTable.wasmPath,
|
||||
},
|
||||
},
|
||||
readonlyStatus: { ready: true },
|
||||
handoffWorkflowSummary: { ready: true },
|
||||
});
|
||||
assertEqual(persistenceSummary.apiName, "machine-session-persistence-summary", "summary API");
|
||||
assertEqual(persistenceSummary.ready, true, "summary ready");
|
||||
assertEqual(persistenceSummary.counts.machineFiles, 4, "summary machine file count");
|
||||
assertEqual(persistenceSummary.missing.length, 0, "summary missing count");
|
||||
assertEqual(
|
||||
persistenceSummary.rows.find(({ id }) => id === "session-readiness")?.value,
|
||||
"ready",
|
||||
"summary readiness row",
|
||||
);
|
||||
assertEqual(
|
||||
persistenceSummary.rows.find(({ id }) => id === "session-load")?.value,
|
||||
"loaded: /work/opfs-session-workflow.ini",
|
||||
"summary load row",
|
||||
);
|
||||
assertEqual(
|
||||
persistenceSummary.rows.find(({ id }) => id === "handoff-readiness")?.value,
|
||||
"ready",
|
||||
"summary handoff row",
|
||||
);
|
||||
|
||||
status.textContent = "browser_opfs_session_workflow_smoke=ok";
|
||||
console.log("browser_opfs_session_workflow_smoke=ok");
|
||||
} catch (error) {
|
||||
status.textContent = `browser_opfs_session_workflow_smoke=failed: ${error.message}`;
|
||||
console.error(error);
|
||||
throw error;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -68,7 +68,7 @@
|
||||
);
|
||||
assertEqual(readyWorkflow.ready, true, "ready workflow readiness");
|
||||
assertEqual(readyWorkflow.httpStatus, 200, "ready workflow HTTP status");
|
||||
assertEqual(readyWorkflow.validation.gateCount, 10, "ready workflow gate count");
|
||||
assertEqual(readyWorkflow.validation.gateCount, 11, "ready workflow gate count");
|
||||
assertEqual(
|
||||
readyWorkflow.validationSummaryViewModel.statusLine,
|
||||
"Ready: Artifact evidence complete",
|
||||
|
||||
81
wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh
Executable file
81
wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh
Executable file
@@ -0,0 +1,81 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
ROOT_DIR="$(cd "$(dirname "$0")/../.." && pwd)"
|
||||
CHROMIUM="${CHROMIUM:-$(command -v chromium || command -v chromium-browser || command -v google-chrome || command -v google-chrome-stable || true)}"
|
||||
|
||||
if [[ -z "$CHROMIUM" ]]; then
|
||||
echo "missing Chromium-compatible browser; set CHROMIUM=/path/to/browser" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "${SKIP_INI_BUILD:-0}" != "1" ]]; then
|
||||
"$ROOT_DIR/tools/build_ini_panel.sh"
|
||||
fi
|
||||
if [[ "${SKIP_INTERP_BUILD:-0}" != "1" ]]; then
|
||||
"$ROOT_DIR/tools/build_wasm_core.sh"
|
||||
fi
|
||||
|
||||
TMP_DIR="$(mktemp -d)"
|
||||
PORT_FILE="$TMP_DIR/port"
|
||||
SERVER_LOG="$TMP_DIR/server.log"
|
||||
CHROME_PROFILE="$TMP_DIR/chrome-profile"
|
||||
mkdir -p "$CHROME_PROFILE"
|
||||
|
||||
cleanup() {
|
||||
if [[ -n "${SERVER_PID:-}" ]]; then
|
||||
kill "$SERVER_PID" 2>/dev/null || true
|
||||
wait "$SERVER_PID" 2>/dev/null || true
|
||||
fi
|
||||
rm -rf "$TMP_DIR"
|
||||
}
|
||||
trap cleanup EXIT
|
||||
|
||||
python3 - <<'PY' "$ROOT_DIR" "$PORT_FILE" >"$SERVER_LOG" 2>&1 &
|
||||
import functools
|
||||
import http.server
|
||||
import pathlib
|
||||
import socketserver
|
||||
import sys
|
||||
|
||||
root = pathlib.Path(sys.argv[1])
|
||||
port_file = pathlib.Path(sys.argv[2])
|
||||
|
||||
handler = functools.partial(http.server.SimpleHTTPRequestHandler, directory=str(root))
|
||||
with socketserver.TCPServer(("127.0.0.1", 0), handler) as httpd:
|
||||
port_file.write_text(str(httpd.server_address[1]), encoding="ascii")
|
||||
httpd.serve_forever()
|
||||
PY
|
||||
SERVER_PID=$!
|
||||
|
||||
for _ in $(seq 1 100); do
|
||||
[[ -s "$PORT_FILE" ]] && break
|
||||
sleep 0.05
|
||||
done
|
||||
|
||||
if [[ ! -s "$PORT_FILE" ]]; then
|
||||
echo "OPFS/session workflow browser smoke HTTP server did not start" >&2
|
||||
cat "$SERVER_LOG" >&2 || true
|
||||
exit 1
|
||||
fi
|
||||
|
||||
PORT="$(cat "$PORT_FILE")"
|
||||
URL="http://127.0.0.1:$PORT/tests/browser/opfs_session_workflow_smoke.html"
|
||||
OUT="$TMP_DIR/chromium.out"
|
||||
|
||||
"$CHROMIUM" \
|
||||
--headless=new \
|
||||
--disable-gpu \
|
||||
--no-sandbox \
|
||||
--user-data-dir="$CHROME_PROFILE" \
|
||||
--virtual-time-budget=10000 \
|
||||
--dump-dom \
|
||||
"$URL" >"$OUT" 2>&1
|
||||
|
||||
if ! grep -Fq "browser_opfs_session_workflow_smoke=ok" "$OUT"; then
|
||||
echo "OPFS/session workflow browser smoke failed" >&2
|
||||
sed -n '1,220p' "$OUT" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "browser_opfs_session_workflow_smoke=ok"
|
||||
@@ -22,6 +22,8 @@ for (const phrase of [
|
||||
"restoreMachineParametersFromOpfs",
|
||||
"loadMachineToolTableFromOpfs",
|
||||
"browser_ini_opfs_smoke=ok",
|
||||
"browser_opfs_session_workflow_smoke=ok",
|
||||
"verify_opfs_session_workflow_browser.sh",
|
||||
"sdk_surface_node_smoke=ok",
|
||||
"host_wasm_opfs_browser_smokes=ok",
|
||||
"verify_no_standalone_cnc_semantics.sh",
|
||||
@@ -37,6 +39,7 @@ assert.match(sdkReadmeText, /OPFS\/session persistence exports/);
|
||||
assert.match(sdkReadmeText, /readMachineSessionReadiness/);
|
||||
assert.match(hostSmokeText, /verify_sdk_surface\.sh/);
|
||||
assert.match(hostSmokeText, /verify_file_service\.sh/);
|
||||
assert.match(hostSmokeText, /verify_opfs_session_workflow_browser\.sh/);
|
||||
assert.match(browserSmokeText, /browser_ini_opfs_smoke=ok/);
|
||||
assert.match(trackerText, /OPFS\/session persistence/);
|
||||
|
||||
|
||||
@@ -60,12 +60,14 @@ for (const phrase of [
|
||||
"build/project-release-readiness.json",
|
||||
"verify_project_release_readiness_artifact.sh",
|
||||
"verify_project_release_artifact_url_workflow.sh",
|
||||
"verify_opfs_session_workflow_browser.sh",
|
||||
"host_wasm_opfs_browser_smokes=ok",
|
||||
"project_release_readiness_artifact_node_smoke=ok",
|
||||
"project_release_artifact_url_workflow_node_smoke=ok",
|
||||
"project_release_gate=ok",
|
||||
"sim_configs_wasm_node_inventory_unexpected_fail=0",
|
||||
"browser_ini_shell_integration_workflow_smoke=ok",
|
||||
"browser_opfs_session_workflow_smoke=ok",
|
||||
"browser_release_artifact_url_workflow_smoke=ok",
|
||||
"project_release_handoff_docs_node_smoke=ok",
|
||||
"L4-USER-M-PROCESS",
|
||||
@@ -90,6 +92,7 @@ for (const phrase of [
|
||||
"verify_interp_wasm.sh",
|
||||
"verify_sim_configs_inventory_wasm.sh",
|
||||
"verify_ini_panel_browser.sh",
|
||||
"verify_opfs_session_workflow_browser.sh",
|
||||
"verify_release_artifact_url_workflow_browser.sh",
|
||||
"verify_ui_node_smokes.sh",
|
||||
"verify_host_smokes.sh",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"gateManifest": {
|
||||
"apiName": "project-release-gate-manifest",
|
||||
"manifestVersion": 1,
|
||||
"gateCount": 10,
|
||||
"gateCount": 11,
|
||||
"gateIds": [
|
||||
"diff-check",
|
||||
"vendor-sync",
|
||||
@@ -33,6 +33,7 @@
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -75,6 +76,12 @@
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_ini_panel_browser.sh",
|
||||
"expectedOutput": "browser_ini_shell_integration_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "release-artifact-url-browser",
|
||||
"label": "Release artifact URL browser workflow smoke",
|
||||
@@ -106,14 +113,14 @@
|
||||
"manifestVersion": 1,
|
||||
"phase": "ready",
|
||||
"ready": true,
|
||||
"gateCount": 10,
|
||||
"passedCount": 10,
|
||||
"gateCount": 11,
|
||||
"passedCount": 11,
|
||||
"unknownCount": 0,
|
||||
"missingGateIds": [],
|
||||
"manifest": {
|
||||
"apiName": "project-release-gate-manifest",
|
||||
"manifestVersion": 1,
|
||||
"gateCount": 10,
|
||||
"gateCount": 11,
|
||||
"gateIds": [
|
||||
"diff-check",
|
||||
"vendor-sync",
|
||||
@@ -121,6 +128,7 @@
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -163,6 +171,12 @@
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_ini_panel_browser.sh",
|
||||
"expectedOutput": "browser_ini_shell_integration_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "release-artifact-url-browser",
|
||||
"label": "Release artifact URL browser workflow smoke",
|
||||
@@ -196,7 +210,7 @@
|
||||
"command": "git diff --check",
|
||||
"expectedOutput": null,
|
||||
"observedOutput": null,
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "explicit-result"
|
||||
@@ -207,7 +221,7 @@
|
||||
"command": "wasm-port/tools/verify_vendor_sync.sh",
|
||||
"expectedOutput": "vendor sync up to date",
|
||||
"observedOutput": "vendor sync up to date",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -218,7 +232,7 @@
|
||||
"command": "wasm-port/tools/verify_no_standalone_cnc_semantics.sh",
|
||||
"expectedOutput": "standalone CNC semantics guard complete",
|
||||
"observedOutput": "standalone CNC semantics guard complete",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -229,7 +243,7 @@
|
||||
"command": "SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_interp_wasm.sh",
|
||||
"expectedOutput": "interp_wasm_node_smoke=ok",
|
||||
"observedOutput": "interp_wasm_node_smoke=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -240,7 +254,7 @@
|
||||
"command": "SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_sim_configs_inventory_wasm.sh",
|
||||
"expectedOutput": "sim_configs_wasm_node_inventory_unexpected_fail=0",
|
||||
"observedOutput": "sim_configs_wasm_node_inventory_unexpected_fail=0",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -251,7 +265,18 @@
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_ini_panel_browser.sh",
|
||||
"expectedOutput": "browser_ini_shell_integration_workflow_smoke=ok",
|
||||
"observedOutput": "browser_ini_shell_integration_workflow_smoke=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok",
|
||||
"observedOutput": "browser_opfs_session_workflow_smoke=ok",
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -262,7 +287,7 @@
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_release_artifact_url_workflow_browser.sh",
|
||||
"expectedOutput": "browser_release_artifact_url_workflow_smoke=ok",
|
||||
"observedOutput": "browser_release_artifact_url_workflow_smoke=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -273,7 +298,7 @@
|
||||
"command": "wasm-port/tests/ui/node/verify_ui_node_smokes.sh",
|
||||
"expectedOutput": "ui_node_smokes=ok",
|
||||
"observedOutput": "ui_node_smokes=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -284,7 +309,7 @@
|
||||
"command": "wasm-port/tests/host/verify_host_smokes.sh",
|
||||
"expectedOutput": "host_wasm_opfs_browser_smokes=ok",
|
||||
"observedOutput": "host_wasm_opfs_browser_smokes=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -295,7 +320,7 @@
|
||||
"command": "wasm-port/tests/host/verify_project_release_gate.sh",
|
||||
"expectedOutput": "project_release_gate=ok",
|
||||
"observedOutput": "project_release_gate=ok",
|
||||
"observedOutputCount": 9,
|
||||
"observedOutputCount": 10,
|
||||
"status": "passed",
|
||||
"passed": true,
|
||||
"evidence": "expected-output"
|
||||
@@ -307,14 +332,14 @@
|
||||
"matrixVersion": 1,
|
||||
"phase": "ready",
|
||||
"ready": true,
|
||||
"gateCount": 10,
|
||||
"passedCount": 10,
|
||||
"gateCount": 11,
|
||||
"passedCount": 11,
|
||||
"unknownCount": 0,
|
||||
"missingGateIds": [],
|
||||
"manifest": {
|
||||
"apiName": "project-release-gate-manifest",
|
||||
"manifestVersion": 1,
|
||||
"gateCount": 10,
|
||||
"gateCount": 11,
|
||||
"gateIds": [
|
||||
"diff-check",
|
||||
"vendor-sync",
|
||||
@@ -322,6 +347,7 @@
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -364,6 +390,12 @@
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_ini_panel_browser.sh",
|
||||
"expectedOutput": "browser_ini_shell_integration_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok"
|
||||
},
|
||||
{
|
||||
"id": "release-artifact-url-browser",
|
||||
"label": "Release artifact URL browser workflow smoke",
|
||||
@@ -439,6 +471,14 @@
|
||||
"status": "passed",
|
||||
"passed": true
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok",
|
||||
"status": "passed",
|
||||
"passed": true
|
||||
},
|
||||
{
|
||||
"id": "release-artifact-url-browser",
|
||||
"label": "Release artifact URL browser workflow smoke",
|
||||
@@ -478,8 +518,8 @@
|
||||
"planVersion": 1,
|
||||
"phase": "ready",
|
||||
"ready": true,
|
||||
"gateCount": 10,
|
||||
"completedCount": 10,
|
||||
"gateCount": 11,
|
||||
"completedCount": 11,
|
||||
"pendingCount": 0,
|
||||
"completedGateIds": [
|
||||
"diff-check",
|
||||
@@ -488,6 +528,7 @@
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -549,6 +590,14 @@
|
||||
"status": "passed",
|
||||
"passed": true
|
||||
},
|
||||
{
|
||||
"id": "opfs-session-browser",
|
||||
"label": "OPFS session browser workflow smoke",
|
||||
"command": "SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
"expectedOutput": "browser_opfs_session_workflow_smoke=ok",
|
||||
"status": "passed",
|
||||
"passed": true
|
||||
},
|
||||
{
|
||||
"id": "release-artifact-url-browser",
|
||||
"label": "Release artifact URL browser workflow smoke",
|
||||
|
||||
@@ -20,6 +20,7 @@ SKIP_TP_BUILD=1 "$ROOT_DIR/tests/wasm/node/verify_tp_wasm.sh"
|
||||
"$ROOT_DIR/tests/docs/node/verify_project_release_handoff_docs.sh"
|
||||
"$ROOT_DIR/tests/ui/node/verify_ui_node_smokes.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_ini_panel_browser.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_opfs_session_workflow_browser.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_interp_browser.sh"
|
||||
|
||||
echo "host_wasm_opfs_browser_smokes=ok"
|
||||
|
||||
@@ -12,6 +12,7 @@ git diff --check
|
||||
SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/wasm/node/verify_interp_wasm.sh"
|
||||
SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/wasm/node/verify_sim_configs_inventory_wasm.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_ini_panel_browser.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_opfs_session_workflow_browser.sh"
|
||||
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 "$ROOT_DIR/tests/browser/verify_release_artifact_url_workflow_browser.sh"
|
||||
"$ROOT_DIR/tests/ui/node/verify_ui_node_smokes.sh"
|
||||
"$ROOT_DIR/tests/sdk/node/verify_project_release_artifact_url_workflow.sh"
|
||||
|
||||
@@ -20,8 +20,8 @@ assert.equal(validation.phase, "ready");
|
||||
assert.deepEqual(validation.missing, []);
|
||||
assert.equal(validation.artifactApiName, "project-release-readiness-report");
|
||||
assert.equal(validation.artifactVersion, 1);
|
||||
assert.equal(validation.gateCount, 10);
|
||||
assert.equal(validation.expectedGateCount, 10);
|
||||
assert.equal(validation.gateCount, 11);
|
||||
assert.equal(validation.expectedGateCount, 11);
|
||||
assert.equal(validation.gateManifestReady, true);
|
||||
assert.equal(validation.gateExecutionManifestReady, true);
|
||||
assert.equal(validation.gateResultMatrixReady, true);
|
||||
@@ -33,6 +33,7 @@ assert.deepEqual(validation.expectedGateIds, [
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -40,7 +41,7 @@ assert.deepEqual(validation.expectedGateIds, [
|
||||
]);
|
||||
assert.equal(artifact.gateManifest.apiName, "project-release-gate-manifest");
|
||||
assert.equal(artifact.gateExecutionManifest.apiName, "project-release-gate-execution-manifest");
|
||||
assert.equal(artifact.gateExecutionManifest.passedCount, 10);
|
||||
assert.equal(artifact.gateExecutionManifest.passedCount, 11);
|
||||
assert.equal(artifact.gateResultMatrix.apiName, "project-release-gate-result-matrix");
|
||||
assert.equal(artifact.gateActionPlan.apiName, "project-release-gate-action-plan");
|
||||
assert.equal(artifact.gateActionPlan.pendingCount, 0);
|
||||
|
||||
@@ -15,6 +15,7 @@ const passedGateResults = {
|
||||
"interp-wasm": true,
|
||||
"sim-config-inventory": true,
|
||||
"ini-panel-browser": true,
|
||||
"opfs-session-browser": true,
|
||||
"release-artifact-url-browser": true,
|
||||
"ui-node-smokes": true,
|
||||
"host-smokes": true,
|
||||
@@ -29,6 +30,7 @@ const report = createProjectReleaseReadinessReport({
|
||||
"interp_wasm_node_smoke=ok",
|
||||
"sim_configs_wasm_node_inventory_unexpected_fail=0",
|
||||
"browser_ini_shell_integration_workflow_smoke=ok",
|
||||
"browser_opfs_session_workflow_smoke=ok",
|
||||
"browser_release_artifact_url_workflow_smoke=ok",
|
||||
"ui_node_smokes=ok",
|
||||
"host_wasm_opfs_browser_smokes=ok",
|
||||
|
||||
@@ -19,7 +19,7 @@ const manifest = createProjectReleaseGateManifest();
|
||||
|
||||
assert.equal(manifest.apiName, "project-release-gate-manifest");
|
||||
assert.equal(manifest.manifestVersion, 1);
|
||||
assert.equal(manifest.gateCount, 10);
|
||||
assert.equal(manifest.gateCount, 11);
|
||||
assert.deepEqual(manifest.gateIds, [
|
||||
"diff-check",
|
||||
"vendor-sync",
|
||||
@@ -27,6 +27,7 @@ assert.deepEqual(manifest.gateIds, [
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"release-artifact-url-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
@@ -41,6 +42,7 @@ assert.deepEqual(
|
||||
"interp_wasm_node_smoke=ok",
|
||||
"sim_configs_wasm_node_inventory_unexpected_fail=0",
|
||||
"browser_ini_shell_integration_workflow_smoke=ok",
|
||||
"browser_opfs_session_workflow_smoke=ok",
|
||||
"browser_release_artifact_url_workflow_smoke=ok",
|
||||
"ui_node_smokes=ok",
|
||||
"host_wasm_opfs_browser_smokes=ok",
|
||||
@@ -51,6 +53,10 @@ assert.equal(
|
||||
manifest.gates.find(({ id }) => id === "release-artifact-url-browser")?.command,
|
||||
"SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_release_artifact_url_workflow_browser.sh",
|
||||
);
|
||||
assert.equal(
|
||||
manifest.gates.find(({ id }) => id === "opfs-session-browser")?.command,
|
||||
"SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_opfs_session_workflow_browser.sh",
|
||||
);
|
||||
|
||||
const partialMatrix = createProjectReleaseGateResultMatrix({
|
||||
gateResults: {
|
||||
@@ -65,14 +71,15 @@ assert.equal(partialMatrix.apiName, "project-release-gate-result-matrix");
|
||||
assert.equal(partialMatrix.matrixVersion, 1);
|
||||
assert.equal(partialMatrix.phase, "waiting");
|
||||
assert.equal(partialMatrix.ready, false);
|
||||
assert.equal(partialMatrix.gateCount, 10);
|
||||
assert.equal(partialMatrix.gateCount, 11);
|
||||
assert.equal(partialMatrix.passedCount, 3);
|
||||
assert.equal(partialMatrix.unknownCount, 7);
|
||||
assert.equal(partialMatrix.unknownCount, 8);
|
||||
assert.deepEqual(partialMatrix.missingGateIds, [
|
||||
"standalone-cnc-semantics",
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
"project-release-gate",
|
||||
@@ -99,9 +106,9 @@ assert.equal(partialExecutionManifest.apiName, "project-release-gate-execution-m
|
||||
assert.equal(partialExecutionManifest.manifestVersion, 1);
|
||||
assert.equal(partialExecutionManifest.phase, "waiting");
|
||||
assert.equal(partialExecutionManifest.ready, false);
|
||||
assert.equal(partialExecutionManifest.gateCount, 10);
|
||||
assert.equal(partialExecutionManifest.gateCount, 11);
|
||||
assert.equal(partialExecutionManifest.passedCount, 3);
|
||||
assert.equal(partialExecutionManifest.unknownCount, 7);
|
||||
assert.equal(partialExecutionManifest.unknownCount, 8);
|
||||
assert.deepEqual(partialExecutionManifest.missingGateIds, partialMatrix.missingGateIds);
|
||||
assert.deepEqual(
|
||||
partialExecutionManifest.rows.filter(({ passed }) => passed).map(({ id, evidence }) => [id, evidence]),
|
||||
@@ -125,9 +132,9 @@ assert.equal(partialActionPlan.apiName, "project-release-gate-action-plan");
|
||||
assert.equal(partialActionPlan.planVersion, 1);
|
||||
assert.equal(partialActionPlan.phase, "waiting");
|
||||
assert.equal(partialActionPlan.ready, false);
|
||||
assert.equal(partialActionPlan.gateCount, 10);
|
||||
assert.equal(partialActionPlan.gateCount, 11);
|
||||
assert.equal(partialActionPlan.completedCount, 3);
|
||||
assert.equal(partialActionPlan.pendingCount, 7);
|
||||
assert.equal(partialActionPlan.pendingCount, 8);
|
||||
assert.deepEqual(partialActionPlan.completedGateIds, [
|
||||
"diff-check",
|
||||
"vendor-sync",
|
||||
@@ -138,13 +145,14 @@ assert.deepEqual(partialActionPlan.pendingGateIds, [
|
||||
"interp-wasm",
|
||||
"sim-config-inventory",
|
||||
"ini-panel-browser",
|
||||
"opfs-session-browser",
|
||||
"ui-node-smokes",
|
||||
"host-smokes",
|
||||
"project-release-gate",
|
||||
]);
|
||||
assert.equal(partialActionPlan.nextGateId, "standalone-cnc-semantics");
|
||||
assert.equal(partialActionPlan.nextCommand, "wasm-port/tools/verify_no_standalone_cnc_semantics.sh");
|
||||
assert.equal(partialActionPlan.commands.length, 7);
|
||||
assert.equal(partialActionPlan.commands.length, 8);
|
||||
assert.equal(partialActionPlan.commands[0].step, 1);
|
||||
assert.equal(partialActionPlan.commands[0].gateId, "standalone-cnc-semantics");
|
||||
assert.equal(partialActionPlan.rows[0].id, "standalone-cnc-semantics");
|
||||
@@ -179,7 +187,7 @@ assert.deepEqual(createProjectReleaseReadinessSummaryViewModel(report), {
|
||||
{
|
||||
id: "gate-results",
|
||||
label: "Release gates",
|
||||
value: "10/10 passed",
|
||||
value: "11/11 passed",
|
||||
},
|
||||
{
|
||||
id: "unknown-gates",
|
||||
@@ -245,7 +253,7 @@ assert.deepEqual(
|
||||
artifactValidationSummary.rows.map(({ id, value }) => [id, value]),
|
||||
[
|
||||
["artifact", "project-release-readiness-report"],
|
||||
["gate-count", "10/10"],
|
||||
["gate-count", "11/11"],
|
||||
["gate-manifest", "ready"],
|
||||
["gate-execution-manifest", "ready"],
|
||||
["gate-result-matrix", "ready"],
|
||||
|
||||
@@ -250,7 +250,7 @@ assert.deepEqual(releaseReadinessWaiting.missing, ["project-release-gate"]);
|
||||
assert.equal(releaseReadinessWaiting.simConfigInventory.unexpectedFail, 0);
|
||||
assert.deepEqual(releaseReadinessWaiting.promotedBlockedFamilies, []);
|
||||
assert.equal(releaseReadinessWaiting.gateActionPlan.apiName, "project-release-gate-action-plan");
|
||||
assert.equal(releaseReadinessWaiting.gateActionPlan.pendingCount, 10);
|
||||
assert.equal(releaseReadinessWaiting.gateActionPlan.pendingCount, createProjectReleaseGateManifest().gateCount);
|
||||
assert.equal(releaseReadinessWaiting.gateActionPlan.nextGateId, "diff-check");
|
||||
assert.equal(
|
||||
releaseReadinessWaiting.rows.find(({ id }) => id === "blocked-runtime-families")?.value,
|
||||
@@ -262,7 +262,7 @@ const releaseReadinessReady = createProjectReleaseReadinessReport({
|
||||
assert.equal(releaseReadinessReady.ready, true);
|
||||
assert.equal(releaseReadinessReady.releaseGate.passed, true);
|
||||
assert.deepEqual(releaseReadinessReady.gateManifest, createProjectReleaseGateManifest());
|
||||
assert.equal(releaseReadinessReady.gateResultMatrix.rows.length, 10);
|
||||
assert.equal(releaseReadinessReady.gateResultMatrix.rows.length, createProjectReleaseGateManifest().gateCount);
|
||||
assert.equal(createProjectReleaseGateActionPlan({
|
||||
gateResultMatrix: releaseReadinessReady.gateResultMatrix,
|
||||
}).ready, false);
|
||||
@@ -277,18 +277,7 @@ assert.equal(
|
||||
true,
|
||||
);
|
||||
const releaseReadinessArtifact = parseProjectReleaseReadinessArtifactJson(JSON.stringify(createProjectReleaseReadinessReport({
|
||||
gateResults: {
|
||||
"diff-check": true,
|
||||
"vendor-sync": true,
|
||||
"standalone-cnc-semantics": true,
|
||||
"interp-wasm": true,
|
||||
"sim-config-inventory": true,
|
||||
"ini-panel-browser": true,
|
||||
"release-artifact-url-browser": true,
|
||||
"ui-node-smokes": true,
|
||||
"host-smokes": true,
|
||||
"project-release-gate": true,
|
||||
},
|
||||
gateResults: Object.fromEntries(createProjectReleaseGateManifest().gateIds.map((id) => [id, true])),
|
||||
})));
|
||||
assert.equal(releaseReadinessArtifact.apiName, "project-release-readiness-report");
|
||||
const releaseReadinessArtifactValidation = createProjectReleaseReadinessArtifactValidation(releaseReadinessArtifact);
|
||||
@@ -300,8 +289,8 @@ assert.deepEqual(releaseReadinessArtifactValidation, {
|
||||
missing: [],
|
||||
artifactApiName: "project-release-readiness-report",
|
||||
artifactVersion: 1,
|
||||
gateCount: 10,
|
||||
expectedGateCount: 10,
|
||||
gateCount: createProjectReleaseGateManifest().gateCount,
|
||||
expectedGateCount: createProjectReleaseGateManifest().gateCount,
|
||||
expectedGateIds: createProjectReleaseGateManifest().gateIds,
|
||||
gateManifestReady: true,
|
||||
gateExecutionManifestReady: true,
|
||||
|
||||
@@ -1306,7 +1306,7 @@ assert.equal(
|
||||
);
|
||||
assert.equal(releaseArtifactValidation.ready, true);
|
||||
assert.equal(releaseArtifactValidation.validation.ready, true);
|
||||
assert.equal(releaseArtifactValidation.gateCount, 10);
|
||||
assert.equal(releaseArtifactValidation.gateCount, 11);
|
||||
const releaseArtifactValidationSummary =
|
||||
createIniPanelShellWorkflowOverviewReleaseReadinessArtifactValidationSummaryViewModel(
|
||||
releaseArtifactValidation,
|
||||
|
||||
Reference in New Issue
Block a user