Guard browser OPFS machine INI wasm path helper

This commit is contained in:
2026-06-14 01:21:48 +08:00
parent 0f5d31b088
commit b41ac3af03
2 changed files with 52 additions and 2 deletions

View File

@@ -4572,6 +4572,10 @@
return `/work/${filename}`;
}
function opfsMachineIniWasmPath(machineId) {
return `/work/${machineId}.ini`;
}
function opfsSessionWasmPaths(ini, parameters, toolTable) {
return { ini, parameters, toolTable };
}
@@ -4628,7 +4632,7 @@
const sessionOptions = {
iniSdk,
iniWasmPath: `/work/${machineId}.ini`,
iniWasmPath: opfsMachineIniWasmPath(machineId),
};
const expectedIniOpfsPath = opfsMachineFilePath(machineId, OPFS_DEFAULT_INI_FILENAME);
assertOpfsIniStaging(
@@ -4638,7 +4642,7 @@
wasmPath: sessionOptions.iniWasmPath,
},
expectedIniOpfsPath,
`/work/${machineId}.ini`,
opfsMachineIniWasmPath(machineId),
);
await verifyRejects(
label,