CS FundamentalsModerateHCL · Tech Mahindra pattern

In top-down integration testing, the top-level module is ready but the lower-level modules it calls are not. What must the testers write, and what would bottom-up integration need instead?

  1. A. Drivers for top-down; stubs for bottom-up
  2. B. Mocks for top-down; nothing for bottom-up
  3. C. Stubs for both
  4. D. Stubs for top-down; drivers for bottom-up

Correct answer: D. Stubs for top-down; drivers for bottom-up

Top-down testing replaces missing called modules with stubs (dummy callees). Bottom-up testing starts from the leaves and needs drivers (dummy callers) to invoke them. Swapping the two is the standard trap.

More Software Engineering, Git and Cloud Basics questions

Exams that ask this topic