From a51b54e14f39b5b8ca4cf7b665bceb92cab4c539 Mon Sep 17 00:00:00 2001 From: Divyansh Singh <40380293+brc-dd@users.noreply.github.com> Date: Sat, 12 Sep 2026 19:25:34 +0530 Subject: [PATCH] slash --- __tests__/base/sharded.test.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/__tests__/base/sharded.test.ts b/__tests__/base/sharded.test.ts index 55cb1a479..056cea95c 100644 --- a/__tests__/base/sharded.test.ts +++ b/__tests__/base/sharded.test.ts @@ -1,5 +1,5 @@ import { readFileSync, readdirSync } from 'node:fs' -import { join, resolve } from 'node:path' +import { join, resolve, sep } from 'node:path' import { fileURLToPath } from 'node:url' import { newPage, realErrors, waitForHydration, type TestPage } from './helpers' @@ -13,7 +13,12 @@ const origin = () => `http://localhost:${process.env['SHARDED_PORT']}` const files = () => readdirSync(dist('assets'), { recursive: true, withFileTypes: true }) .filter((e) => e.isFile()) - .map((e) => join(e.parentPath, e.name).slice(dist('assets').length + 1)) + .map((e) => + join(e.parentPath, e.name) + .slice(dist('assets').length + 1) + .split(sep) + .join('/') + ) const isShardedPath = (f: string) => /^[0-2]\/[^/]+$/.test(f)