AWS Certified Developer Associate DVA-C02 Practice Question
Considering a developer is creating a serverless application function that interacts with a NoSQL database service provided by a cloud provider, how can the developer effectively implement unit tests for the function to simulate interactions with the database without deploying the code?
Employ a mocking framework to create a simulated environment of the NoSQL database.
Connect the function to a live instance of the NoSQL database for each test to ensure accurate results.
Rely on manual testing after deployment for each iteration of the function code.
Only use console logging within the function to verify the correct behavior during test runs.