InterviewStack.io LogoInterviewStack.io

Test Levels and the Test Pyramid Questions

How unit, integration, component, end-to-end and contract tests fit together and where each provides the most value. Covers the test pyramid and the competing shapes proposed against it (the testing trophy and the honeycomb), multi-layer test architecture, contract testing as the seam between services, choosing the right level to catch a given class of defect cheaply, and what to run per commit versus per release. Includes the cost and confidence trade-offs between fast low-level tests and slower, broader system tests. The scope is which level a test belongs at and why. Deciding how much to invest in testing and where to prioritize under time pressure is covered separately.

HardSystem Design
65 practiced

Design a test pyramid tailored to an ML-enabled recommendation feature. Cover unit tests for data transformation and feature-engineering code, integration and component tests for model scoring and feature stores, model-validation tests (data-quality checks, drift detection, performance thresholds), and end-to-end tests including offline evaluation and online A/B validation. Define acceptance criteria and the monitoring alarms you would use to detect model regressions in production.

That is every published Test Levels and the Test Pyramid question for Machine Learning Engineer so far. Browse the other topics in this category, or practice this one interactively.