[LEA] added test for Forcefield

This commit is contained in:
Evan Kranzler 2021-02-24 20:55:22 -05:00
parent 5f23ccf24c
commit c01e1cd133

View file

@ -0,0 +1,38 @@
package org.mage.test.cards.replacement.prevent;
import mage.constants.PhaseStep;
import mage.constants.Zone;
import org.junit.Test;
import org.mage.test.serverside.base.CardTestPlayerBase;
/**
* @author TheElk801
*/
public class ForcefieldTest extends CardTestPlayerBase {
private static final String giant = "Bonebreaker Giant";
private static final String lion = "Silvercoat Lion";
@Test
public void testForcefield() {
addCard(Zone.BATTLEFIELD, playerB, "Wastes", 2);
addCard(Zone.BATTLEFIELD, playerB, "Forcefield");
addCard(Zone.BATTLEFIELD, playerA, giant);
addCard(Zone.BATTLEFIELD, playerA, lion);
attack(1, playerA, giant);
attack(1, playerA, lion);
setChoice(playerB, giant);
setChoice(playerB, lion);
activateAbility(1, PhaseStep.DECLARE_BLOCKERS, playerB, "{1}");
activateAbility(1, PhaseStep.DECLARE_BLOCKERS, playerB, "{1}");
setStrictChooseMode(true);
setStopAt(1, PhaseStep.END_TURN);
execute();
assertAllCommandsUsed();
assertLife(playerB, 20 - 1 - 1);
}
}