Commit 4c252752 authored by Thomas DENIS's avatar Thomas DENIS
Browse files

Version 3 de HandTraqueTest

parent 2f92ba78
...@@ -126,10 +126,6 @@ class HandTraqueTest { ...@@ -126,10 +126,6 @@ class HandTraqueTest {
assertTrue(hand.getDefausse().containsAll(testCards)); assertTrue(hand.getDefausse().containsAll(testCards));
} }
@Test @Test
public void testTakeBackPlaceCard(){
//TODO
}
@Test
public void testTakeBackPlaceCardGiven(){ public void testTakeBackPlaceCardGiven(){
PlaceCard card = new PlaceCard(CardName.ANTRE,"antre","antre",1,"url","bleu"); PlaceCard card = new PlaceCard(CardName.ANTRE,"antre","antre",1,"url","bleu");
List<PlaceCard> testCards = new ArrayList<>(); List<PlaceCard> testCards = new ArrayList<>();
...@@ -152,11 +148,25 @@ class HandTraqueTest { ...@@ -152,11 +148,25 @@ class HandTraqueTest {
} }
@Test @Test
public void testTakeBackPlayedPlaceCards(){ public void testTakeBackPlayedPlaceCards(){
//TODO PlaceCard card = new PlaceCard(CardName.ANTRE,"antre","antre",1,"url","bleu");
List<PlaceCard> testCards = new ArrayList<>();
testCards.add(card);
hand.setPlaceCards(testCards);
hand.playPlaceCard(testCards);
hand.takeBackPlayedPlaceCards();
assertTrue(hand.getPlaceCards().containsAll(testCards));
assertTrue(hand.getPlaceCardsPlayed().isEmpty());
} }
@Test @Test
public void testTakeBackAllPlaceCardFromDefausse(){ public void testTakeBackAllPlaceCardFromDefausse(){
//TODO PlaceCard card = new PlaceCard(CardName.ANTRE,"antre","antre",1,"url","bleu");
List<PlaceCard> testCards = new ArrayList<>();
testCards.add(card);
hand.setPlaceCards(testCards);
hand.playPlaceCard(testCards);
hand.takeBackAllPlaceCardFromDefausse();
assertTrue(hand.getPlaceCards().containsAll(testCards));
assertTrue(hand.getDefausse().isEmpty());
} }
@Test @Test
public void testAddPlaceCard(){ public void testAddPlaceCard(){
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment