Skip to content

Commit

Permalink
SLSCMN-20 Middy package (#20)
Browse files Browse the repository at this point in the history
SLSCMN-20 revert to middy 4.7.0
  • Loading branch information
mwarman authored Mar 1, 2024
1 parent 80bb23e commit 09dfed6
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 189 deletions.
26 changes: 13 additions & 13 deletions jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export default {
// Make calling deprecated APIs throw helpful error messages
// errorOnDeprecated: false,

extensionsToTreatAsEsm: ['.ts'],
// extensionsToTreatAsEsm: ['.ts'],

// The default configuration for fake timers
// fakeTimers: {
Expand Down Expand Up @@ -88,9 +88,9 @@ export default {
// ],

// A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module
moduleNameMapper: {
'^@middy$': '<rootDir>/node_modules/@middy',
},
// moduleNameMapper: {
// '^@middy$': '<rootDir>/node_modules/@middy',
// },

// An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader
// modulePathIgnorePatterns: [],
Expand Down Expand Up @@ -175,17 +175,17 @@ export default {
// testRunner: "jest-circus/runner",

// A map from regular expressions to paths to transformers
transform: {
'^.+\\.tsx?$': [
'ts-jest',
{
useESM: true,
},
],
},
// transform: {
// '^.+\\.tsx?$': [
// 'ts-jest',
// {
// useESM: true,
// },
// ],
// },

// An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
transformIgnorePatterns: ['/node_modules/(?!(@middy)/)'],
// transformIgnorePatterns: ['/node_modules/(?!(@middy)/)'],

// An array of regexp pattern strings that are matched against all modules before the module loader will automatically return a mock for them
// unmockedModulePathPatterns: undefined,
Expand Down
191 changes: 25 additions & 166 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 9 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
"build": "rollup -c --bundleConfigAsCjs",
"clean": "rimraf coverage dist",
"lint": "eslint src/**/*.ts",
"test": "NODE_OPTIONS=--experimental-vm-modules jest",
"test:coverage": "npm run test -- --coverage --silent --verbose --color",
"test:watch": "npm run test -- --watch"
"test": "jest",
"test:coverage": "jest --coverage --silent --verbose --color",
"test:watch": "jest --watch"
},
"repository": {
"type": "git",
Expand All @@ -32,10 +32,9 @@
"@aws-sdk/client-dynamodb": "^3.523.0",
"@aws-sdk/client-sqs": "^3.523.0",
"@aws-sdk/lib-dynamodb": "^3.523.0",
"@middy/core": "^5.2.4",
"@middy/http-event-normalizer": "^5.2.4",
"@middy/http-json-body-parser": "^5.2.4",
"@middy/util": "^5.2.4",
"@middy/core": "^4.7.0",
"@middy/http-event-normalizer": "^4.7.0",
"@middy/http-json-body-parser": "^4.7.0",
"@rollup/plugin-commonjs": "^25.0.4",
"@rollup/plugin-node-resolve": "^15.2.1",
"@rollup/plugin-terser": "^0.4.3",
Expand Down Expand Up @@ -66,9 +65,9 @@
"@aws-sdk/client-dynamodb": "^3.523.0",
"@aws-sdk/client-sqs": "^3.523.0",
"@aws-sdk/lib-dynamodb": "^3.523.0",
"@middy/core": "^5.2.4",
"@middy/http-event-normalizer": "^5.2.4",
"@middy/http-json-body-parser": "^5.2.4",
"@middy/core": "^4.7.0",
"@middy/http-event-normalizer": "^4.7.0",
"@middy/http-json-body-parser": "^4.7.0",
"http-status": "^1.7.4",
"joi": "^17.12.2",
"winston": "^3.11.0"
Expand Down

0 comments on commit 09dfed6

Please sign in to comment.