mirror of
https://github.com/correl/mage.git
synced 2024-11-15 03:00:16 +00:00
Added a test.
This commit is contained in:
parent
8acfbf0ab3
commit
32a123e799
1 changed files with 70 additions and 0 deletions
|
@ -7,6 +7,7 @@ package org.mage.test.cards.triggers;
|
|||
|
||||
import mage.constants.PhaseStep;
|
||||
import mage.constants.Zone;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestPlayerBase;
|
||||
|
||||
|
@ -116,4 +117,73 @@ public class WorldgorgerDragonTest extends CardTestPlayerBase {
|
|||
|
||||
}
|
||||
|
||||
/**
|
||||
* v9: Worldgorger Dragon + Animate Dead is still acting up (yey complex rules interactions!).
|
||||
* The first time you return Animate Dead from Worldgorger's exile, it works like it's supposed
|
||||
* to. You have to pick a creature, and it brings it back. But if you pick Worldgorger Dragon
|
||||
* again, it allows you to not pick a creature, and regardless of whether you choose to skip or pick
|
||||
* a different creature, it always returns the first creature you picked. Kind of hard to explain,
|
||||
* but here's how to reproduce:
|
||||
*
|
||||
* 1) Cast Animate Dead, targeting Worldgorger Dragon
|
||||
* 2) Worldgorger Dragon will exile Animate Dead, killing the dragon and returning the permanents
|
||||
* 3) Select Worldgorger again
|
||||
* 4) Step 2 repeats
|
||||
* 5) Attempt to select a different creature. Worldgorger Dragon is returned instead.
|
||||
*
|
||||
*/
|
||||
@Test
|
||||
@Ignore
|
||||
public void testWithAnimateDeadDifferentTargets() {
|
||||
addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2);
|
||||
|
||||
// When Worldgorger Dragon enters the battlefield, exile all other permanents you control.
|
||||
// When Worldgorger Dragon leaves the battlefield, return the exiled cards to the battlefield under their owners' control.
|
||||
addCard(Zone.GRAVEYARD, playerA, "Worldgorger Dragon", 1);
|
||||
|
||||
addCard(Zone.GRAVEYARD, playerA, "Silvercoat Lion", 1);
|
||||
// When Animate Dead enters the battlefield, if it's on the battlefield, it loses "enchant creature card in a graveyard"
|
||||
// and gains "enchant creature put onto the battlefield with Animate Dead." Return enchanted creature card to the battlefield
|
||||
// under your control and attach Animate Dead to it. When Animate Dead leaves the battlefield, that creature's controller sacrifices it.
|
||||
addCard(Zone.HAND, playerA, "Animate Dead");
|
||||
addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3);
|
||||
// Instant {X}{R}{R}
|
||||
// Volcanic Geyser deals X damage to target creature or player.
|
||||
addCard(Zone.HAND, playerA, "Volcanic Geyser", 1);
|
||||
// When Staunch Defenders enters the battlefield, you gain 4 life.
|
||||
addCard(Zone.BATTLEFIELD, playerA, "Staunch Defenders", 1);
|
||||
|
||||
|
||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Animate Dead", "Worldgorger Dragon");
|
||||
addTarget(playerA, "Worldgorger Dragon");
|
||||
addTarget(playerA, "Worldgorger Dragon");
|
||||
addTarget(playerA, "Silvercoat Lion");
|
||||
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R}");
|
||||
|
||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Volcanic Geyser", playerB, 9);
|
||||
setChoice(playerA, "X=7");
|
||||
|
||||
setStopAt(1, PhaseStep.BEGIN_COMBAT);
|
||||
execute();
|
||||
|
||||
assertGraveyardCount(playerA, "Worldgorger Dragon", 1);
|
||||
assertPermanentCount(playerA, "Silvercoat Lion", 1);
|
||||
|
||||
assertLife(playerA, 24);
|
||||
assertLife(playerB, 11);
|
||||
|
||||
assertGraveyardCount(playerA, "Volcanic Geyser", 1);
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in a new issue