Search the courses, subjects, tracks, games and features, or jump straight to a page.
3 cards from this section. Quick, good the night before a test.
What annotation do we use to mark a test method in JUnit 5?
Think about how we denote what the purpose of the method is.
What is the purpose of the assertEquals method?
It involves two values we want to compare.
What does the @Test annotation signify in a JUnit test?
This annotation is crucial for identifying which methods to run as tests.
Is it true that the assertEquals method can compare two values?
Think about what assertions in tests typically verify.
Write a comprehensive unit test that covers multiple conditions for a divide method and includes edge cases.
Think about how you handle division by zero in programming.
Given a class StringManipulator with a method that reverses a string, create a parameterized test to test multiple input strings.
Make sure the reverse method handles multiple strings correctly.
5 more questions in this section. Enroll free to practise them all.
Enroll free