Unit tests with mocked dependencies pass for both an API gateway and a new token-validation service. Before staging, the team must confirm the two components work correctly together, including when the service returns a deny decision or an error. Which two actions BEST do this? (Choose two.)
Choose 2 answers
Show the answer
Correct answersC. Run tests against the gateway and the service deployed together in an isolated test environmentD. Assert that the gateway blocks requests when the real service returns a deny or an error response
AWhy not this: Unit tests with a mocked gateway isolate one component, so they cannot reveal problems in how the two really interact.
BWhy not this: A canary release is a gradual production rollout, not a pre-staging check of component interaction.
CWhy this is right: Deploying both components together lets tests exercise the real interface between them, which is what integration testing covers.
DWhy this is right: Checking that the gateway handles the real service's deny and error responses tests the interaction behaviour between the two components.
Integration testing exercises real components together and checks how they handle each other's outputs, including denials and errors. Higher unit coverage with a mocked gateway still never tests the real interaction, and a canary release is a production rollout step, not a pre-staging interaction test.