Raw
1 const glob = require(`glob`)
2
3 const pkgs = glob
4 .sync(`${__dirname}/*/`)
5 .map((p) => p.replace(__dirname, `<rootDir>/integration-tests`))
6
7 module.exports = {
8 testEnvironment: `node`,
9 testTimeout: 10000,
10 rootDir: `../`,
11 roots: pkgs,
12 projects: ["<rootDir>/integration-tests/http/jest.config.js"],
13 testPathIgnorePatterns: [
14 `/examples/`,
15 `/www/`,
16 `/dist/`,
17 `/node_modules/`,
18 `__tests__/fixtures`,
19 `__testfixtures__`,
20 `.cache`,
21 ],
22 transform: {
23 "^.+\\.[jt]s$": [
24 "@swc/jest",
25 {
26 jsc: {
27 parser: {
28 syntax: "typescript",
29 decorators: true,
30 },
31 transform: {
32 useDefineForClassFields: false,
33 legacyDecorator: true,
34 decoratorMetadata: true,
35 },
36 target: "ES2021",
37 },
38 },
39 ],
40 },
41 setupFiles: ["<rootDir>/integration-tests/setup-env.js"],
42 setupFilesAfterEnv: ["<rootDir>/integration-tests/setup.js"],
43 }