In reply to
Graham (@grahamcox82@fosstodon.org)
Post details So, when writing code it's important to test that it works. And especially on boundaries - e.g. where you interact with other systems.
In both #rust and #golang, the #AWS SDK recommends injecting a mock version of the SDK client so you can control how it acts. But it's impossible to construct the error types in both cases, so it's impossible to test the error paths.
Am I missing something here? This seems like a *huge* oversight! I'll have a look at some code I've got to see if I can reproduce the same issue, but one alternative is using a Facade pattern to wrap the client (example code is Java but same intent)
Sat, 18 Mar 2023 08:59 by Jamie Tanna
.
This post was filed under replies .
Interactions with this post Interactions with this post Below you can find the interactions that this page has had using WebMention .
Have you written a response to this post? Let me know the URL:
Do you not have a website set up with WebMention capabilities? You can use Comment Parade .
Due to laziness, this site uses client-side JavaScript to render the webmentions, rather than them being rendered server-side. If you do not wish to enable JavaScript, that's fair enough, but you won't be able to automagically see what Webmentions I've received - sorry!