JOBSEEKERS
Login
Sign Up
Jobseeker
Employer
Staffing Firm
Direct Client
Spring interview questions part 46
Spring interview questions part 46
Back
Take as many assements as you can to improve your validate your skill rating
Total Questions: 20
1. This manages a test context for a test and triggers test execution listeners:-
A. Test context
B. Test context manager
C. Test context listener
D. Test execution listener
Show Correct Answer
Correct Answer is :
Test context manager
2. This defines a listener interface; by implementing this, you can listen to test execution events.
A. Test context
B. Test context manager
C. Test context listener
D. Test execution listener
Show Correct Answer
Correct Answer is :
Test execution listener
3. Spring provides convenient TestContext support classes for:-
A. JUnit3
B. JUnit4
C. TestNG5
D. All of the mentioned
Show Correct Answer
Correct Answer is :
All of the mentioned
4. JUnit 4 allows you to annotate your test methods with:-
A. @Test
B. @Autowire
C. @JTest
D. None of the mentioned
Show Correct Answer
Correct Answer is :
@Test
5. Usually, a test and its target class are located in the same package, but the source files of tests are stored in a separate directory.
A. TRUE
B. FALSE
C.
D.
Show Correct Answer
Correct Answer is :
TRUE
6. Method to perform cleanup tasks:-
A. finalize
B. tearDown
C. all of the mentioned
D. none of the mentioned
Show Correct Answer
Correct Answer is :
all of the mentioned
7. The static assert methods is declared in the:-
A. org.junit.Assert
B. org.junit.*
C. all of the mentioned
D. none of the mentioned
Show Correct Answer
Correct Answer is :
all of the mentioned
8. Attribute which specifies the exception type:-
A. after
B. expected
C. before
D. test
Show Correct Answer
Correct Answer is :
expected
9. Test data sets are provided by data providers, which are methods with the:-
A. @DataProvider
B. @Autowire
C. @JTest
D. None of the mentioned
Show Correct Answer
Correct Answer is :
@DataProvider
10. An object that simulates a dependent object:-
A. stub
B. mock
C. test
D. none of the mentioned
Show Correct Answer
Correct Answer is :
stub
11. An Object which usually knows how its methods are expected to be called:-
A. stub
B. mock
C. test
D. none of the mentioned
Show Correct Answer
Correct Answer is :
mock
12. Libraries that can help create mock objects:-
A. EasyMock
B. jMock
C. All of the mentioned
D. None of the mentioned
Show Correct Answer
Correct Answer is :
All of the mentioned
13. Test used to test several units in combination as a whole.
A. Integration tests
B. JUnit4
C. TestNG5
D. All of the mentioned
Show Correct Answer
Correct Answer is :
Integration tests
14. Spring supports web controller testing by providing Servlet API:-
A. MockHttpServletRequest
B. MockHttpServletResponse
C. MockHttpSession
D. All of the mentioned
Show Correct Answer
Correct Answer is :
All of the mentioned
15. Interface implemented by locale resolver.
A. localeResolver
B. tiles
C. front controller
D. none of the mentioned
Show Correct Answer
Correct Answer is :
localeResolver
16. You can define a locale resolver by registering a bean of type LocaleResolver in the web application context.
A. TRUE
B. FALSE
C.
D.
Show Correct Answer
Correct Answer is :
TRUE
17. Default localeResolver used by Spring.
A. AcceptHeaderLocale
B. AcceptHeader
C. AcceptHeaderLocaleResolver
D. AcceptLocaleResolver
Show Correct Answer
Correct Answer is :
AcceptHeaderLocaleResolver
18. AcceptHeaderLocaleResolver esolves locales by inspecting the accept-language header of an HTTP request.
A. TRUE
B. FALSE
C.
D.
Show Correct Answer
Correct Answer is :
TRUE
19. Alternative way to resolve locales.
A. AcceptHeaderLocale
B. AcceptHeader
C. AcceptHeaderLocaleResolver
D. SessionLocaleResolver
Show Correct Answer
Correct Answer is :
SessionLocaleResolver
20. Property which indicates how many seconds this cookie should be persisted.
A. cookieMaxAge
B. cookieName
C. cookieAge
D. none of the mentioned
Show Correct Answer
Correct Answer is :
cookieMaxAge
Similar Interview Questions
Search for latest jobs
Find Jobs