From d3596b006709b86ff67987962e91950ecccbd10e Mon Sep 17 00:00:00 2001 From: Andy Haynes Date: Tue, 6 Aug 2024 12:43:59 -0700 Subject: [PATCH] test: update configuration --- packages/accounts/jest.config.ts | 11 ++++------- packages/biometric-ed25519/jest.config.ts | 11 ++++------- packages/crypto/jest.config.ts | 11 ++++------- packages/keystores-browser/jest.config.ts | 17 +++++++---------- packages/keystores-node/jest.config.ts | 11 ++++------- packages/keystores/jest.config.ts | 11 ++++------- packages/providers/jest.config.ts | 9 +++------ packages/signers/jest.config.ts | 11 ++++------- packages/transactions/jest.config.ts | 11 ++++------- packages/utils/jest.config.ts | 11 ++++------- packages/wallet-account/jest.config.ts | 11 ++++------- 11 files changed, 46 insertions(+), 79 deletions(-) diff --git a/packages/accounts/jest.config.ts b/packages/accounts/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/accounts/jest.config.ts +++ b/packages/accounts/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/biometric-ed25519/jest.config.ts b/packages/biometric-ed25519/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/biometric-ed25519/jest.config.ts +++ b/packages/biometric-ed25519/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/crypto/jest.config.ts b/packages/crypto/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/crypto/jest.config.ts +++ b/packages/crypto/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/keystores-browser/jest.config.ts b/packages/keystores-browser/jest.config.ts index 6725228929..d9d914d549 100644 --- a/packages/keystores-browser/jest.config.ts +++ b/packages/keystores-browser/jest.config.ts @@ -3,14 +3,11 @@ export default { collectCoverage: true, testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", - transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { - tsconfig: { - allowJs: true - } - } - }, + transform: { + '^.+\\.[tj]s$': ['ts-jest', { + tsconfig: { + allowJs: true + } + }] + }, }; diff --git a/packages/keystores-node/jest.config.ts b/packages/keystores-node/jest.config.ts index 6725228929..545639fcad 100644 --- a/packages/keystores-node/jest.config.ts +++ b/packages/keystores-node/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/keystores/jest.config.ts b/packages/keystores/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/keystores/jest.config.ts +++ b/packages/keystores/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/providers/jest.config.ts b/packages/providers/jest.config.ts index a85677b0c9..0d356a2622 100644 --- a/packages/providers/jest.config.ts +++ b/packages/providers/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true + allowJs: true } - } + }] }, }; diff --git a/packages/signers/jest.config.ts b/packages/signers/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/signers/jest.config.ts +++ b/packages/signers/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/transactions/jest.config.ts b/packages/transactions/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/transactions/jest.config.ts +++ b/packages/transactions/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/utils/jest.config.ts b/packages/utils/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/utils/jest.config.ts +++ b/packages/utils/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, }; diff --git a/packages/wallet-account/jest.config.ts b/packages/wallet-account/jest.config.ts index a85677b0c9..3b66313239 100644 --- a/packages/wallet-account/jest.config.ts +++ b/packages/wallet-account/jest.config.ts @@ -4,13 +4,10 @@ export default { testEnvironment: 'node', testRegex: "(/tests/.*|(\\.|/)(test|spec))\\.[jt]sx?$", transform: { - '^.+\\.[tj]s$': 'ts-jest' - }, - globals: { - 'ts-jest': { + '^.+\\.[tj]s$': ['ts-jest', { tsconfig: { - allowJs: true - } - } + allowJs: true, + }, + }], }, };