@cloudflare/vitest-pool-workers 0.16.11 → 0.16.12
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.
package/dist/pool/index.mjs
CHANGED
|
@@ -55,7 +55,7 @@ var __name = (target, value) => __defProp(target, "name", {
|
|
|
55
55
|
});
|
|
56
56
|
|
|
57
57
|
//#endregion
|
|
58
|
-
//#region ../workers-utils/dist/chunk-
|
|
58
|
+
//#region ../workers-utils/dist/chunk-UFU4JGIG.mjs
|
|
59
59
|
function isCompatDate(str) {
|
|
60
60
|
return /^\d{4}-\d{2}-\d{2}$/.test(str);
|
|
61
61
|
}
|
|
@@ -84,8 +84,7 @@ function mapWorkerMetadataBindings(bindings) {
|
|
|
84
84
|
case "json":
|
|
85
85
|
configObj.vars = {
|
|
86
86
|
...configObj.vars ?? {},
|
|
87
|
-
name: binding.
|
|
88
|
-
json: binding.json
|
|
87
|
+
[binding.name]: binding.json
|
|
89
88
|
};
|
|
90
89
|
break;
|
|
91
90
|
case "kv_namespace":
|
|
@@ -2516,6 +2515,8 @@ async function handleModuleFallbackRequest(vite, request) {
|
|
|
2516
2515
|
const referrerDir = posixPath.dirname(referrer);
|
|
2517
2516
|
let specifier = getApproximateSpecifier(target, referrerDir);
|
|
2518
2517
|
if (specifier.startsWith("file:")) specifier = fileURLToPath(specifier);
|
|
2518
|
+
const rawSpecifier = url.searchParams.get("rawSpecifier");
|
|
2519
|
+
if (rawSpecifier?.startsWith("file:")) specifier = ensurePosixLikePath(fileURLToPath(rawSpecifier));
|
|
2519
2520
|
if (isWindows) {
|
|
2520
2521
|
if (target[0] === "/") target = target.substring(1);
|
|
2521
2522
|
if (referrer[0] === "/") referrer = referrer.substring(1);
|