diff --git a/agent/testing/helpers.ts b/agent/testing/helpers.ts index d76357c9..fa87647e 100644 --- a/agent/testing/helpers.ts +++ b/agent/testing/helpers.ts @@ -51,12 +51,10 @@ export interface ITestHttpServer { server: T; } -const sourcedir = getSourcedir(__dirname); - export async function runKoaServer(onlyCloseOnFinal = true): Promise { const koa = new Koa(); const router = new KoaRouter() as ITestKoaServer; - const exampleOrgPath = Path.join(sourcedir, 'html', 'example.org.html'); + const exampleOrgPath = Path.join(__dirname, 'html', 'example.org.html'); const exampleOrgHtml = Fs.readFileSync(exampleOrgPath, 'utf-8'); const upload = KoaMulter(); // note you can pass `multer` options here @@ -99,8 +97,8 @@ export async function runKoaServer(onlyCloseOnFinal = true): Promise {