Examples of PlayingCard


Examples of uk.co.iscoding.freecell.cards.PlayingCard

        assertEquals("Joker card name is correct", "Joker", JOKER.toString());
    }

    @Test
    public void testDeepClone() {
        PlayingCard clone = FIVE_OF_DIAMONDS.deepClone();
        assertTrue("Clone is equivalent card", FIVE_OF_DIAMONDS.equals(clone));
        assertFalse("Clone is not the same card", FIVE_OF_DIAMONDS == clone);
    }
View Full Code Here

Examples of uk.co.iscoding.freecell.cards.PlayingCard

        assertFalse("Clone is not the same card", FIVE_OF_DIAMONDS == clone);
    }

    @Test
    public void testEquals() {
        assertTrue("Equivalent cards are equal", FIVE_OF_DIAMONDS.equals(new PlayingCard(Suit.DIAMONDS, Rank.FIVE)));
        assertFalse("Non equivalent cards are not equal", KING_OF_CLUBS.equals(FIVE_OF_DIAMONDS));
        assertFalse("Joker is not equivalent to normal card", NINE_OF_DIAMONDS.equals(JOKER));
        assertTrue("Joker is equivalent to another Joker", JOKER.equals(new PlayingCard(Suit.JOKER, Rank.JOKER)));
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.