Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
private void Test(String description, PokerHand.Result expected, String playerHand, String opponentHand)
{
PokerHand player = new PokerHand(playerHand);
PokerHand opponent = new PokerHand(opponentHand);
-->PokerHand.Result r = player.compareWith(opponent);
In your example test class, and also in your second test the variable r is never used, causing the method compareWith() to be called twice.
You could either remove the line with the --> next to it or change:
assertEquals(description + ":", expected.toString(), player.compareWith(opponent).toString());
to
assertEquals(description + ":", expected.toString(), r.toString());
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution