Skip to content

armgit / alook

Public Imported from GitHub
0

Multi-Agent Collaboration for Team and Friends

test(web): resolve homepage FAQ paths by module

Gus572767ffd63a
diff --git a/src/web/src/components/home/homepage-faq.test.ts b/src/web/src/components/home/homepage-faq.test.ts
index b362bd397..f49476636 100644
--- a/src/web/src/components/home/homepage-faq.test.ts
+++ b/src/web/src/components/home/homepage-faq.test.ts
@@ -1,14 +1,13 @@
import { readFileSync } from "node:fs"
-import path from "node:path"
import { describe, expect, it } from "vitest"
import { FAQ_PAGE_SCHEMA, HOME_FAQS } from "./landing-content"
function componentSource() {
- return readFileSync(path.join(process.cwd(), "src/components/home/homepage-faq.tsx"), "utf8")
+ return readFileSync(new URL("./homepage-faq.tsx", import.meta.url), "utf8")
}
function stylesSource() {
- return readFileSync(path.join(process.cwd(), "src/components/home/landing-page.module.css"), "utf8")
+ return readFileSync(new URL("./landing-page.module.css", import.meta.url), "utf8")
}
describe("HomepageFaq", () => {