Goal: Test Javascript like gotestaws
- Mock AWS calls
- Assert their parameters are correct
- Simulate their responses to ensure the logic using them are handling them as expected
- TODO: Simulate exception handling
The mock.calls[0][0]
method of asserting params feels a little wrong.
- https://aws.amazon.com/blogs/developer/mocking-modular-aws-sdk-for-javascript-v3-in-unit-tests/
- https://twitter.com/radzikowski_m/status/1510967905411899395
Big con of this approach is that the existing code base would have to be refactored.
Switching from the established aws-sdk-mock to the new aws-sdk-client-mock.