Adding Automated Tests to AWS Lambda .NET Executable
Explore how to effectively add automated tests to AWS Lambda functions using .NET by separating business logic from function handlers. This lesson helps you understand how to write readable and maintainable tests for serverless applications while considering different testing strategies and techniques.
We'll cover the following...
Automated testing
Testing an AWS Lambda application with .NET runtime and top-level C# statements is more involved than testing a basic AWS Lambda console application. There are multiple ways to do it, and some are more advanced than others. For example, since the function handler is not associated with any method or class, we have to use some complicated reflections logic to identify it in our test methods. It may work, but the code we’ll end up with won’t be easily readable or understood by novice developers.
The following playground shows an easier way. This ...