Skip to content

Commit

Permalink
chore: cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Sep 8, 2023
1 parent b0dc4bb commit 3635486
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 3 additions & 0 deletions packages/vitest/src/integrations/browser/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ export async function createBrowserServer(project: WorkspaceProject, configFile:
port: defaultBrowserPort,
}

// browser never runs in middleware mode
server.middlewareMode = false

config.server = server
config.server.fs ??= {}
config.server.fs.allow = config.server.fs.allow || []
Expand Down
5 changes: 1 addition & 4 deletions packages/vitest/src/node/workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,7 @@ export async function initializeProject(workspacePath: string | number, ctx: Vit
],
}

const server = await createServer(config)

if (ctx.config.api?.port)
await server.listen()
await createServer(config)

return project
}
Expand Down

0 comments on commit 3635486

Please sign in to comment.