Skip to content

Commit 277d085

Browse files
authored
feat(testing-sdk): Refactor testing library to not use a running server (#344)
*Issue #, if available:* *Description of changes:* Currently the testing library spins up a whole server to simulate the Lambda service. This is unnecessary overhead, and also can cause issues with mocking, since its an extra dependency that customers need to avoid mocking. Additionally, it can create issues due to port conflicts. This change makes it so the server is now simulated using worker communication instead of creating an actual socket. By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
1 parent aacc208 commit 277d085

File tree

48 files changed

+1949
-5584
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+1949
-5584
lines changed

package-lock.json

Lines changed: 11 additions & 727 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
"@tsconfig/node20": "^20.1.5",
3939
"@types/argparse": "^2.0.17",
4040
"@types/aws-lambda": "^8.10.150",
41-
"@types/express": "^5.0.2",
4241
"@types/jest": "^30.0.0",
4342
"@types/morgan": "^1.9.10",
4443
"@types/supertest": "^6.0.3",

packages/aws-durable-execution-sdk-js-testing/package.json

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,12 @@
4242
"@eslint/compat": "^1.3.0",
4343
"@eslint/js": "^9.29.0",
4444
"@types/aws-lambda": "^8.10.150",
45-
"@types/express": "^5.0.2",
4645
"@types/morgan": "^1.9.10",
4746
"@types/sinonjs__fake-timers": "^15.0.1",
4847
"@types/supertest": "^6.0.3",
4948
"eslint": "^9.29.0",
5049
"eslint-config-prettier": "^10.1.5",
5150
"eslint-plugin-jest": "^29.0.1",
52-
"express": "^5.1.0",
5351
"jest": "^30.0.3",
5452
"supertest": "^7.1.1",
5553
"tsx": "^4.20.5",
@@ -59,8 +57,7 @@
5957
"dependencies": {
6058
"@aws-sdk/client-lambda": "*",
6159
"@sinonjs/fake-timers": "^13.0.5",
62-
"@smithy/smithy-client": "^4.9.1",
63-
"express": "^5.1.0"
60+
"@smithy/smithy-client": "^4.9.1"
6461
},
6562
"peerDependencies": {
6663
"@aws/durable-execution-sdk-js": "*"

0 commit comments

Comments
 (0)