in Education by
Using which annotation non visible or private method can be tested? (a) @VisibleForTesting (b) @NonVisibleForTesting (c) @Visible (d) @NonVisible The question was posed to me in an internship interview. Question is taken from Annotations topic in section Application Lifecycle & Annotations of Java Select the correct answer from above options JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
Right choice is (a) @VisibleForTesting The explanation: Using @VisibleForTesting annotation private or non visible method can be tested.

Related questions

0 votes
    How private method can be called using reflection? (a) getDeclaredFields (b) getDeclaredMethods (c) getMethods ... for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
    How private field can be called using reflection? (a) getDeclaredFields (b) getDeclaredMethods (c) getMethods ... for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
0 votes
    A new web browser window can be opened using which method of the Window object? (a) createtab() ( ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 23, 2021 in Education by JackTerrance
0 votes
0 votes
0 votes
    Which version of Java introduced annotation? (a) Java 5 (b) Java 6 (c) Java 7 (d) Java 8 ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
0 votes
    Which of the following is not pre defined annotation in Java? (a) @Deprecated (b) @Overriden (c) ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
0 votes
0 votes
    What will happen if you set the private flag as 1? (a) Test will be run only by the ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 22, 2021 in Education by JackTerrance
0 votes
    Which of this method can be used to make the main thread to be executed last among all the threads ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
...