From 86c25fc7a71359b5939eab2f7ea4a61b1e5e75db Mon Sep 17 00:00:00 2001 From: Bruna Campos Date: Thu, 5 Oct 2023 10:27:58 -0300 Subject: [PATCH] add e2e config --- .gitignore | 2 ++ e2e/demo/demo.spec.ts | 4 ---- e2e/jest.config.ts | 4 ++-- jest.config.ts | 2 +- tsconfig.json | 4 ++-- 5 files changed, 7 insertions(+), 9 deletions(-) delete mode 100644 e2e/demo/demo.spec.ts diff --git a/.gitignore b/.gitignore index 9dd76421..e7d9529d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +e2e.config.ts + # ============= Lint ============= # Cache eslint .eslintcache diff --git a/e2e/demo/demo.spec.ts b/e2e/demo/demo.spec.ts deleted file mode 100644 index 7fe8d120..00000000 --- a/e2e/demo/demo.spec.ts +++ /dev/null @@ -1,4 +0,0 @@ -test('demo', () => { - //config.access_token; - expect(true).toBeTruthy(); -}); diff --git a/e2e/jest.config.ts b/e2e/jest.config.ts index f8a77fe1..98e0ddb1 100644 --- a/e2e/jest.config.ts +++ b/e2e/jest.config.ts @@ -1,8 +1,8 @@ import jestConfig from '../jest.config'; +jestConfig.rootDir = '../'; jestConfig.testPathIgnorePatterns = [ - '/node_modules/', - '/src/' + 'src' ]; export default jestConfig; diff --git a/jest.config.ts b/jest.config.ts index 54391a15..1061b699 100644 --- a/jest.config.ts +++ b/jest.config.ts @@ -12,7 +12,7 @@ const jestConfig: JestConfigWithTsJest = { 'text-summary' ], testMatch: [ - '**/?(*.)+(spec|test).[tj]s?(x)' + '**/?(*.)spec.ts' ], transform: { '^.+\\.(ts|tsx)$': 'ts-jest' }, moduleNameMapper: pathsToModuleNameMapper(compilerOptions.paths, { prefix: '' }), diff --git a/tsconfig.json b/tsconfig.json index 302f3b5b..f6808185 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -10,7 +10,7 @@ "sourceMap": false, "outDir": "./dist", "baseUrl": "./", - "rootDir": "./src", + "rootDir": ".", "resolveJsonModule": true, "experimentalDecorators": true, "emitDecoratorMetadata": true, @@ -22,5 +22,5 @@ "@clients/*": ["./src/clients/*"] } }, - "include": ["src/**/*"] + "include": ["src/**/*", "e2e/**/*"] }