|
1 | 1 | // Import Node.js Dependencies |
2 | | -import fs from "node:fs"; |
3 | 2 | import { fileURLToPath } from "node:url"; |
4 | 3 | import { after, before, describe, test } from "node:test"; |
5 | 4 | import { once } from "node:events"; |
@@ -31,7 +30,6 @@ const kConfigKey = "___config"; |
31 | 30 | const kGlobalDispatcher = getGlobalDispatcher(); |
32 | 31 | const kMockAgent = new MockAgent(); |
33 | 32 | const kBundlephobiaPool = kMockAgent.get("https://bundlephobia.com"); |
34 | | -const kDefaultPayloadPath = path.join(process.cwd(), "nsecure-result.json"); |
35 | 33 | const kProjectRootDir = path.join(import.meta.dirname, "..", "..", ".."); |
36 | 34 | const kComponentsDir = path.join(kProjectRootDir, "public", "components"); |
37 | 35 |
|
@@ -60,12 +58,6 @@ describe("httpServer", { concurrency: 1 }, () => { |
60 | 58 | await once(httpServer.server!, "listening"); |
61 | 59 |
|
62 | 60 | enableDestroy(httpServer.server!); |
63 | | - |
64 | | - if (fs.existsSync(kDefaultPayloadPath) === false) { |
65 | | - // When running tests on CI, we need to create the nsecure-result.json file |
66 | | - const payload = fs.readFileSync(JSON_PATH, "utf-8"); |
67 | | - fs.writeFileSync(kDefaultPayloadPath, payload); |
68 | | - } |
69 | 61 | }, { timeout: 5000 }); |
70 | 62 |
|
71 | 63 | after(async() => { |
|
0 commit comments