Do you happen to know how to get passed this issue with running tests with the Vitest Pool Workers l

Do you happen to know how to get passed this issue with running tests with the Vitest Pool Workers library with Workflows that are bound to a Worker and DO? Adding it in causes a similar error to what fredviken is getting. Do I need to do any extra imports in the vitest.config file as I have the workflow in a separate folder? The durable object class gets resolved without issue, but not the workflow.

Snippet of my wrangler.jsonc below

{
  // Other info
  // ...
  "compatibility_date": "2025-03-17",
  "compatibility_flags": ["nodejs_compat"],

  "observability": {
    "enabled": true
  },

  "durable_objects": {
    "bindings": [
      {
        "name": "TASKS",
        "class_name": "Task"
      }
    ]
  },

  "migrations": [
    {
      "new_sqlite_classes": ["Task"],
      "tag": "v1"
    }
  ],

  "workflows": [
    {
      "binding": "TASK_WORKFLOW",
      "class_name": "TaskWorkflow",
      "name": "task-workflow"
    }
  ],
// Some other bindings with Queues, Services and Rules
// ...
}
Was this page helpful?