@cloudflare/vitest-plugin 1.2.8 → 1.3.0
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
|
@@ -45401,7 +45401,7 @@ function mapWorkerMetadataBindings(bindings) {
|
|
|
45401
45401
|
}, {});
|
|
45402
45402
|
}
|
|
45403
45403
|
__name$3(mapWorkerMetadataBindings, "mapWorkerMetadataBindings");
|
|
45404
|
-
var DEFAULT_COMPAT_DATE = "2026-09-
|
|
45404
|
+
var DEFAULT_COMPAT_DATE = "2026-09-26";
|
|
45405
45405
|
function constructWranglerConfig(config$1) {
|
|
45406
45406
|
const mappedBindings = mapWorkerMetadataBindings(config$1.bindings);
|
|
45407
45407
|
const durableObjectClassNames = config$1.bindings.filter((binding) => binding.type === "durable_object_namespace" && binding.script_name === config$1.name).map((durableObject) => durableObject.class_name);
|
|
@@ -61264,7 +61264,7 @@ __name$1(createWorkerUploadForm, "createWorkerUploadForm");
|
|
|
61264
61264
|
//#endregion
|
|
61265
61265
|
//#region ../remote-bindings/dist/index.mjs
|
|
61266
61266
|
var import_undici = require_undici();
|
|
61267
|
-
var version = "0.0.
|
|
61267
|
+
var version = "0.0.37";
|
|
61268
61268
|
var NoDefaultValueProvided = class extends UserError$1 {
|
|
61269
61269
|
constructor() {
|
|
61270
61270
|
super("This command cannot be run in a non-interactive context", { telemetryMessage: "remote bindings prompt default missing" });
|
|
@@ -62206,6 +62206,12 @@ const WorkerBindingSchema = z$1.strictObject({
|
|
|
62206
62206
|
props: z$1.record(z$1.string(), z$1.unknown()).optional(),
|
|
62207
62207
|
dev: RemoteBindingDevSchema.optional()
|
|
62208
62208
|
});
|
|
62209
|
+
const WorkflowBindingSchema = z$1.strictObject({
|
|
62210
|
+
type: z$1.literal("workflow"),
|
|
62211
|
+
name: z$1.string(),
|
|
62212
|
+
worker: z$1.string(),
|
|
62213
|
+
exportName: z$1.string()
|
|
62214
|
+
});
|
|
62209
62215
|
const D1BindingSchema = z$1.strictObject({
|
|
62210
62216
|
type: z$1.literal("d1"),
|
|
62211
62217
|
name: z$1.string().optional(),
|
|
@@ -62370,7 +62376,8 @@ const KnownBindingSchema = z$1.discriminatedUnion("type", [
|
|
|
62370
62376
|
return value.tunnelId !== void 0 && value.networkId !== void 0 ? `"vpc-network" bindings must specify exactly one of "tunnelId" or "networkId", not both` : `"vpc-network" bindings must specify either "tunnelId" or "networkId"`;
|
|
62371
62377
|
} }),
|
|
62372
62378
|
WorkerBindingSchema,
|
|
62373
|
-
z$1.strictObject({ type: z$1.literal("worker-loader") })
|
|
62379
|
+
z$1.strictObject({ type: z$1.literal("worker-loader") }),
|
|
62380
|
+
WorkflowBindingSchema
|
|
62374
62381
|
]);
|
|
62375
62382
|
const UnsafeBindingSchema = z$1.looseObject({
|
|
62376
62383
|
type: z$1.templateLiteral(["unsafe:", z$1.string().min(1)]),
|
|
@@ -63323,6 +63330,14 @@ function convertBindingsAndAssets(config$1, result) {
|
|
|
63323
63330
|
case "worker-loader":
|
|
63324
63331
|
workerLoaders.push({ binding: name });
|
|
63325
63332
|
break;
|
|
63333
|
+
case "workflow":
|
|
63334
|
+
workflows.push({
|
|
63335
|
+
binding: name,
|
|
63336
|
+
name: binding.name,
|
|
63337
|
+
class_name: binding.exportName,
|
|
63338
|
+
script_name: binding.worker
|
|
63339
|
+
});
|
|
63340
|
+
break;
|
|
63326
63341
|
}
|
|
63327
63342
|
}
|
|
63328
63343
|
if (kvNamespaces.length) result.kv_namespaces = kvNamespaces;
|
|
@@ -64478,10 +64493,11 @@ function getDurableObjectClasses(worker) {
|
|
|
64478
64493
|
return result;
|
|
64479
64494
|
}
|
|
64480
64495
|
/**
|
|
64481
|
-
* Gets a set of class names for Workflows defined in the SELF Worker
|
|
64496
|
+
* Gets a set of class names for Workflows defined in the SELF Worker, either
|
|
64497
|
+
* declared in its `exports` or bound to it.
|
|
64482
64498
|
*/
|
|
64483
64499
|
function getWorkflowClasses(worker, configWorkerName) {
|
|
64484
|
-
const result =
|
|
64500
|
+
const result = new Set(Object.keys(worker.workflowExports ?? {}));
|
|
64485
64501
|
if (worker.workflows === void 0) return result;
|
|
64486
64502
|
for (const key of Object.keys(worker.workflows)) {
|
|
64487
64503
|
const designator = worker.workflows[key];
|
|
@@ -64490,7 +64506,10 @@ function getWorkflowClasses(worker, configWorkerName) {
|
|
|
64490
64506
|
else workerName = worker.name;
|
|
64491
64507
|
if (isWorkflowDesignatorToSelf(designator, workerName)) {
|
|
64492
64508
|
result.add(designator.className);
|
|
64493
|
-
worker.workflows[key] = {
|
|
64509
|
+
worker.workflows[key] = {
|
|
64510
|
+
...designator,
|
|
64511
|
+
scriptName: void 0
|
|
64512
|
+
};
|
|
64494
64513
|
}
|
|
64495
64514
|
}
|
|
64496
64515
|
return result;
|