🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Testing Spring Boot: all 10 questions

Quiz: Testing Spring Boot · Question 10 of 10

What is the main problem with using @SpringBootTest for every test?

What is the main problem with using @SpringBootTest for every test?

  1. A.It cannot test controllers
  2. B.It does not support Mockito
  3. C.It starts the whole application, so the test suite becomes slow
  4. D.It cannot use a database
Answer & explanation

Correct answer: It starts the whole application, so the test suite becomes slow

Prefer many fast unit tests and slices, and a few full-app tests.

Can you get the rest right without peeking?

Take the timed Quiz: Testing Spring Boot quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →