Answered step by step
Verified Expert Solution
Question
1 Approved Answer
7.13.1. Design Test Cases: State Testing A Stringutils class contains a reverse () method, with a signature as presented below. List test cases, which would
7.13.1. Design Test Cases: State Testing A Stringutils class contains a reverse () method, with a signature as presented below. List test cases, which would verify that this method really reverses the input String! Listing 7.35. Signature of reverse Method public String reverse (String s) {...} 7.13.2. Design Test Cases: Interactions Testing UserService Impl class contains the assignPassword() method, as presented on Listing 7.36. The method uses two collaborators to successfully perform its task: userDAO and securityService. Listing 7.36. assignPassword() method private UserDAO user DAO; private Security Service security Service; public void assignPassword (User user) throws Exception { String passwordMd5 = security Service.md5 (user.getPassword()); user.setPassword (passwordMd5); userDAO. updateUser (user); Design the test cases for this method! Please note that this time you will have to think not only about the input parameters (user), but also about the values returned (or exceptions thrown!) by securityService and userDAO
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started