Question: NOTE: ** I ONLY NEED THE TESTING CODE FOR THIS. I ALREADY FOUND THE MODIFIED CODE*** JUnit5 Modify your Rock Paper Scissor Lizard Spock game

NOTE: ** I ONLY NEED THE TESTING CODE FOR THIS. I ALREADY FOUND THE MODIFIED CODE*** JUnit5

Modify your Rock Paper Scissor Lizard Spock game from Week 6 to generate a random number for Player 2, use the random number to assign it a string selection (rock paper scissor lizard spock) and assign that as Player 2's choice. Complete the work of assigning Player 2's random choice in a method. It should take no parameters but return a string that represents Player 2's random choice. The implementation should use the Random class to get your random number.

Now you are only getting a choice from player one and playing until they enter done using the sentinel value loop. The rest of your program should stay the same. You can use your program with the nested if statements or the switch statement.

Verify that your file still works with your testing file. If Lizard and Spock are not implemented, verify that those tests are added. Make sure all your tests are exhaustive (uppercase, funky case, same plays, all options, bad input). Note: you do not need to test your random player 2 option method. After all, how could you? (The answer is not easily; therefore, you do not need to test it - just your determine who the winner is method.)

The assignment is worth 15 points for the two files. Upload your class and the testing file to the assignment. Both files must be submitted in order to be graded.

NOTE: ** I ONLY NEED THE TESTING CODE FOR THIS. I ALREADY FOUND THE MODIFIED CODE*** JUnit5

NOTE: ** I ONLY NEED THE TESTING CODE FOR THIS. I ALREADY FOUND THE MODIFIED CODE*** JUnit 5

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!