mirror of
https://github.com/magefree/mage.git
synced 2026-01-10 12:52:06 -08:00
Dauthi Voidwalker - correct code for #8141 and same cards (see comments in fd719ad287);
This commit is contained in:
parent
affd33c23b
commit
a3ca9fc03a
8 changed files with 142 additions and 88 deletions
|
|
@ -0,0 +1,42 @@
|
|||
package org.mage.test.cards.single.mh2;
|
||||
|
||||
import mage.constants.PhaseStep;
|
||||
import mage.constants.Zone;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestPlayerBase;
|
||||
|
||||
/**
|
||||
* @author JayDi85
|
||||
*/
|
||||
public class DauthiVoidwalkerTest extends CardTestPlayerBase {
|
||||
|
||||
@Test
|
||||
public void test_Play() {
|
||||
// If a card would be put into an opponent's graveyard from anywhere, instead exile it with a void counter on it.
|
||||
// {T}, Sacrifice Dauthi Voidwalker: Choose an exiled card an opponent owns with a void counter on it. You may play it this turn without paying its mana cost.
|
||||
addCard(Zone.BATTLEFIELD, playerA, "Dauthi Voidwalker", 1);
|
||||
//
|
||||
addCard(Zone.BATTLEFIELD, playerB, "Balduvian Bears", 1);
|
||||
//
|
||||
addCard(Zone.HAND, playerA, "Lightning Bolt");
|
||||
addCard(Zone.BATTLEFIELD, playerA, "Mountain");
|
||||
|
||||
// kill B's creature and exile with void counter
|
||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", "Balduvian Bears");
|
||||
waitStackResolved(1, PhaseStep.PRECOMBAT_MAIN);
|
||||
checkExileCount("after exile", 1, PhaseStep.PRECOMBAT_MAIN, playerA, "Balduvian Bears", 1);
|
||||
|
||||
// can play it for free
|
||||
activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}, Sacrifice");
|
||||
setChoice(playerA, "Balduvian Bears");
|
||||
waitStackResolved(1, PhaseStep.PRECOMBAT_MAIN);
|
||||
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Balduvian Bears");
|
||||
waitStackResolved(1, PhaseStep.PRECOMBAT_MAIN);
|
||||
checkPermanentCount("after play", 1, PhaseStep.PRECOMBAT_MAIN, playerA, "Balduvian Bears", 1);
|
||||
|
||||
setStrictChooseMode(true);
|
||||
setStopAt(2, PhaseStep.END_TURN);
|
||||
execute();
|
||||
assertAllCommandsUsed();
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue