Question 1
A mature Test Automation Solution (TAS) for a large-scale logistics platform is experiencing a high rate of false negatives. Analysis reveals that many failures are due to test data inconsistencies across distributed microservices. For example, a test creating a shipment in the 'Orders' service fails because the corresponding product information is not yet propagated to the 'Inventory' service. Which approach provides the MOST robust and scalable solution to this data synchronization problem?
Answer and explanation
Correct answer: C
This is the most robust solution. Hardcoded waits are brittle and lead to either unnecessarily slow tests or continued intermittent failures. Direct database insertion bypasses business logic and APIs, potentially creating invalid states and making tests less realistic. A polling mechanism (dynamic wait) ensures the test proceeds exactly when the system is ready, making it both efficient and reliable. This approach respects the asynchronous and distributed nature of microservices.