Skip to content

Commit a406723

Browse files
committed
fix(relay): read migrations in checkout paths with spaces
1 parent cefb544 commit a406723

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

‎infra/relay/src/environments/ManagedTunnelLimits.test.ts‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import * as Context from "effect/Context";
44
import * as Effect from "effect/Effect";
55
import * as FileSystem from "effect/FileSystem";
66
import * as Layer from "effect/Layer";
7+
import * as Path from "effect/Path";
78
import * as Semaphore from "effect/Semaphore";
89
import { PGlite } from "@electric-sql/pglite";
910
import { drizzle } from "drizzle-orm/pglite";
@@ -187,7 +188,10 @@ describe("ManagedTunnelLimits", () => {
187188
Effect.promise(() => PGlite.create()),
188189
(client) => Effect.promise(() => client.close()),
189190
);
190-
const migrationsDir = new URL("../../migrations/postgres/", import.meta.url).pathname;
191+
const path = yield* Path.Path;
192+
const migrationsDir = yield* path.fromFileUrl(
193+
new URL("../../migrations/postgres/", import.meta.url),
194+
);
191195
const migrations = (yield* fs.readDirectory(migrationsDir)).toSorted();
192196
const applyMigrations = (names: ReadonlyArray<string>) =>
193197
Effect.forEach(names, (name) =>

0 commit comments

Comments
 (0)