mirror of
https://github.com/correl/mage.git
synced 2024-11-15 03:00:16 +00:00
Tests for Lightning Bolt and Sejiri Merfolk.
This commit is contained in:
parent
d89131e63c
commit
f0cc3d1d0f
2 changed files with 60 additions and 0 deletions
|
@ -0,0 +1,36 @@
|
|||
package org.mage.test.cards.conditional;
|
||||
|
||||
import junit.framework.Assert;
|
||||
import mage.Constants;
|
||||
import mage.abilities.keyword.FirstStrikeAbility;
|
||||
import mage.abilities.keyword.LifelinkAbility;
|
||||
import mage.game.permanent.Permanent;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestBase;
|
||||
|
||||
/**
|
||||
* @author ayrat
|
||||
*/
|
||||
public class SejiriMerfolkTest extends CardTestBase {
|
||||
|
||||
@Test
|
||||
public void testWithoutPlains() {
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Sejiri Merfolk");
|
||||
execute();
|
||||
Permanent merfolk = getPermanent("Sejiri Merfolk", playerA.getId());
|
||||
Assert.assertNotNull(merfolk);
|
||||
Assert.assertFalse(merfolk.getAbilities().contains(FirstStrikeAbility.getInstance()));
|
||||
Assert.assertFalse(merfolk.getAbilities().contains(LifelinkAbility.getInstance()));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testWithPlains() {
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Sejiri Merfolk");
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Plains");
|
||||
execute();
|
||||
Permanent merfolk = getPermanent("Sejiri Merfolk", playerA.getId());
|
||||
Assert.assertNotNull(merfolk);
|
||||
Assert.assertTrue(merfolk.getAbilities().contains(FirstStrikeAbility.getInstance()));
|
||||
Assert.assertTrue(merfolk.getAbilities().contains(LifelinkAbility.getInstance()));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
package org.mage.test.cards.damage;
|
||||
|
||||
import mage.Constants;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestBase;
|
||||
|
||||
/**
|
||||
* @author ayrat
|
||||
*/
|
||||
public class LightningBoltTest extends CardTestBase {
|
||||
|
||||
@Test
|
||||
public void testDamageOpponent() {
|
||||
addCard(Constants.Zone.HAND, playerA, "Mountain");
|
||||
addCard(Constants.Zone.HAND, playerA, "Lightning Bolt");
|
||||
|
||||
playLand(playerA, "Mountain");
|
||||
castSpell(playerA, "Lightning Bolt");
|
||||
|
||||
execute();
|
||||
assertLife(playerA, 20);
|
||||
assertLife(playerB, 17);
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue