mirror of
https://github.com/correl/mage.git
synced 2025-03-07 20:53:18 -10:00
Added test that reproduces issue with Oblivion Ring second ability
This commit is contained in:
parent
16c0afe4c1
commit
97e5f6aa16
1 changed files with 52 additions and 0 deletions
|
@ -0,0 +1,52 @@
|
|||
package org.mage.test.cards.triggers;
|
||||
|
||||
import mage.Constants;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestBase;
|
||||
import org.mage.test.serverside.base.CardTestPlayerBase;
|
||||
|
||||
/**
|
||||
* @author noxx
|
||||
*
|
||||
* Card: When Mausoleum Guard dies, put two 1/1 white Spirit creature tokens with flying onto the battlefield.
|
||||
*/
|
||||
public class OblivionRingTest extends CardTestPlayerBase {
|
||||
|
||||
@Test
|
||||
public void testFirstTriggeredAbility() {
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Plains", 3);
|
||||
addCard(Constants.Zone.HAND, playerA, "Oblivion Ring");
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerB, "Craw Wurm");
|
||||
|
||||
castSpell(1, Constants.PhaseStep.PRECOMBAT_MAIN, playerA, "Oblivion Ring");
|
||||
|
||||
setStopAt(2, Constants.PhaseStep.END_TURN);
|
||||
execute();
|
||||
|
||||
assertLife(playerA, 20);
|
||||
assertLife(playerB, 20);
|
||||
assertPermanentCount(playerA, "Oblivion Ring", 1);
|
||||
assertPermanentCount(playerB, "Frost Titan", 0);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSecondTriggeredAbility() {
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Plains", 3);
|
||||
addCard(Constants.Zone.HAND, playerA, "Oblivion Ring");
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerB, "Craw Wurm");
|
||||
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerB, "Forest", 2);
|
||||
addCard(Constants.Zone.HAND, playerB, "Naturalize");
|
||||
|
||||
castSpell(1, Constants.PhaseStep.PRECOMBAT_MAIN, playerA, "Oblivion Ring");
|
||||
castSpell(2, Constants.PhaseStep.PRECOMBAT_MAIN, playerB, "Naturalize", "Oblivion Ring");
|
||||
|
||||
setStopAt(2, Constants.PhaseStep.END_TURN);
|
||||
execute();
|
||||
|
||||
assertLife(playerA, 20);
|
||||
assertLife(playerB, 20);
|
||||
assertPermanentCount(playerA, "Oblivion Ring", 0);
|
||||
assertPermanentCount(playerB, "Frost Titan", 1);
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue