mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
* Fixed failing test.
This commit is contained in:
parent
445f824424
commit
01d0183e49
1 changed files with 30 additions and 37 deletions
|
@ -1,9 +1,7 @@
|
||||||
|
|
||||||
package org.mage.test.cards.cost.modification;
|
package org.mage.test.cards.cost.modification;
|
||||||
|
|
||||||
import mage.constants.PhaseStep;
|
import mage.constants.PhaseStep;
|
||||||
import mage.constants.Zone;
|
import mage.constants.Zone;
|
||||||
import org.junit.Ignore;
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.mage.test.serverside.base.CardTestPlayerBase;
|
import org.mage.test.serverside.base.CardTestPlayerBase;
|
||||||
|
|
||||||
|
@ -16,7 +14,7 @@ public class KaradorGhostChieftainTest extends CardTestPlayerBase {
|
||||||
@Test
|
@Test
|
||||||
public void castReducedTwo() {
|
public void castReducedTwo() {
|
||||||
setStrictChooseMode(true);
|
setStrictChooseMode(true);
|
||||||
|
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Plains", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Plains", 1);
|
||||||
|
@ -29,7 +27,7 @@ public class KaradorGhostChieftainTest extends CardTestPlayerBase {
|
||||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
||||||
setStopAt(1, PhaseStep.BEGIN_COMBAT);
|
setStopAt(1, PhaseStep.BEGIN_COMBAT);
|
||||||
execute();
|
execute();
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,7 +43,7 @@ public class KaradorGhostChieftainTest extends CardTestPlayerBase {
|
||||||
@Test
|
@Test
|
||||||
public void castReducedSeven() {
|
public void castReducedSeven() {
|
||||||
setStrictChooseMode(true);
|
setStrictChooseMode(true);
|
||||||
|
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Plains", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Plains", 1);
|
||||||
|
@ -57,19 +55,19 @@ public class KaradorGhostChieftainTest extends CardTestPlayerBase {
|
||||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
||||||
setStopAt(1, PhaseStep.BEGIN_COMBAT);
|
setStopAt(1, PhaseStep.BEGIN_COMBAT);
|
||||||
execute();
|
execute();
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void castCastMultipleFromGraveyard() {
|
public void castCastMultipleFromGraveyard() {
|
||||||
setStrictChooseMode(true);
|
setStrictChooseMode(true);
|
||||||
|
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Plains", 4);
|
addCard(Zone.BATTLEFIELD, playerA, "Plains", 4);
|
||||||
addCard(Zone.GRAVEYARD, playerA, "Silvercoat Lion", 7);
|
addCard(Zone.GRAVEYARD, playerA, "Silvercoat Lion", 7);
|
||||||
|
|
||||||
// Exile target creature you control, then return that card to the battlefield under your control.
|
// Exile target creature you control, then return that card to the battlefield under your control.
|
||||||
addCard(Zone.HAND, playerA, "Cloudshift");// Instant {W}
|
addCard(Zone.HAND, playerA, "Cloudshift");// Instant {W}
|
||||||
// Karador, Ghost Chieftain costs {1} less to cast for each creature card in your graveyard.
|
// Karador, Ghost Chieftain costs {1} less to cast for each creature card in your graveyard.
|
||||||
|
@ -77,70 +75,65 @@ public class KaradorGhostChieftainTest extends CardTestPlayerBase {
|
||||||
addCard(Zone.HAND, playerA, "Karador, Ghost Chieftain");// {5}{B}{G}{W}
|
addCard(Zone.HAND, playerA, "Karador, Ghost Chieftain");// {5}{B}{G}{W}
|
||||||
|
|
||||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
||||||
|
|
||||||
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
||||||
|
|
||||||
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Cloudshift", "Karador, Ghost Chieftain");
|
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Cloudshift", "Karador, Ghost Chieftain");
|
||||||
|
|
||||||
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
||||||
|
|
||||||
setStopAt(3, PhaseStep.BEGIN_COMBAT);
|
setStopAt(3, PhaseStep.BEGIN_COMBAT);
|
||||||
execute();
|
execute();
|
||||||
|
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Silvercoat Lion", 2);
|
assertPermanentCount(playerA, "Silvercoat Lion", 2);
|
||||||
assertGraveyardCount(activePlayer, "Cloudshift", 1);
|
assertGraveyardCount(activePlayer, "Cloudshift", 1);
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
// @Ignore // It's not possible yet to select which ability to use to allow a asThoughtAs effect
|
|
||||||
public void test_castFromGraveyardWithDifferentApprovers() {
|
public void test_castFromGraveyardWithDifferentApprovers() {
|
||||||
setStrictChooseMode(true);
|
setStrictChooseMode(true);
|
||||||
|
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Plains", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Plains", 3);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
addCard(Zone.BATTLEFIELD, playerA, "Forest", 1);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2);
|
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2);
|
||||||
addCard(Zone.BATTLEFIELD, playerA, "Island", 3);
|
addCard(Zone.BATTLEFIELD, playerA, "Island", 1);
|
||||||
|
|
||||||
// {1}{B}: Target attacking Zombie gains indestructible until end of turn.
|
// {1}{B}: Target attacking Zombie gains indestructible until end of turn.
|
||||||
addCard(Zone.LIBRARY, playerA, "Accursed Horde", 1); // Creature Zombie {2}{B}{B}
|
addCard(Zone.LIBRARY, playerA, "Accursed Horde", 1); // Creature Zombie {2}{B}{B}
|
||||||
skipInitShuffling();
|
skipInitShuffling();
|
||||||
|
|
||||||
addCard(Zone.GRAVEYARD, playerA, "Silvercoat Lion", 5);
|
addCard(Zone.GRAVEYARD, playerA, "Silvercoat Lion", 5);
|
||||||
|
|
||||||
// Karador, Ghost Chieftain costs {1} less to cast for each creature card in your graveyard.
|
// Karador, Ghost Chieftain costs {1} less to cast for each creature card in your graveyard.
|
||||||
// During each of your turns, you may cast one creature card from your graveyard.
|
// During each of your turns, you may cast one creature card from your graveyard.
|
||||||
addCard(Zone.HAND, playerA, "Karador, Ghost Chieftain");// {5}{B}{G}{W}
|
addCard(Zone.HAND, playerA, "Karador, Ghost Chieftain");// {5}{B}{G}{W}
|
||||||
|
|
||||||
// When Gisa and Geralf enters the battlefield, put the top four cards of your library into your graveyard.
|
// When Gisa and Geralf enters the battlefield, put the top four cards of your library into your graveyard.
|
||||||
// During each of your turns, you may cast a Zombie creature card from your graveyard.
|
// During each of your turns, you may cast a Zombie creature card from your graveyard.
|
||||||
addCard(Zone.HAND, playerA, "Gisa and Geralf"); // CREATURE {2}{U}{B} (4/4)
|
addCard(Zone.HAND, playerA, "Gisa and Geralf"); // CREATURE {2}{U}{B} (4/4)
|
||||||
|
|
||||||
|
|
||||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Karador, Ghost Chieftain");
|
||||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Gisa and Geralf");
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Gisa and Geralf");
|
||||||
|
|
||||||
|
|
||||||
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Accursed Horde");
|
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Accursed Horde");
|
||||||
setChoice(playerA, "During each of your turns, you may cast a Zombie creature card from your graveyard"); // Choose the permitting object
|
setChoice(playerA, "During each of your turns, you may cast a Zombie creature card from your graveyard"); // Choose the permitting object
|
||||||
|
|
||||||
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Silvercoat Lion");
|
||||||
|
|
||||||
|
|
||||||
setStopAt(3, PhaseStep.BEGIN_COMBAT);
|
setStopAt(3, PhaseStep.BEGIN_COMBAT);
|
||||||
execute();
|
execute();
|
||||||
|
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
assertPermanentCount(playerA, "Karador, Ghost Chieftain", 1);
|
||||||
assertPermanentCount(playerA, "Gisa and Geralf", 1);
|
assertPermanentCount(playerA, "Gisa and Geralf", 1);
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Silvercoat Lion", 1);
|
assertPermanentCount(playerA, "Silvercoat Lion", 1);
|
||||||
assertPermanentCount(playerA, "Accursed Horde", 1);
|
assertPermanentCount(playerA, "Accursed Horde", 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue