diff --git a/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java b/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java index 04f56b64d9..f2339e7a2c 100644 --- a/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java @@ -79,4 +79,27 @@ public class ProtectionFromColorTest extends CardTestPlayerBase { } + /** + * Test that the creature is also protected from targeting + */ + @Test + public void testProtectionTargeting() { + // {3}{W} + // Protection from white + String archonOfAbsolution = "Archon of Absolution"; + // {W} + // Exile target creature + String pathToExile = "Path to Exile"; + + addCard(Zone.BATTLEFIELD, playerA, archonOfAbsolution); + + addCard(Zone.HAND, playerB, pathToExile); + addCard(Zone.BATTLEFIELD, playerB, "Plains"); + + checkPlayableAbility("Protection works", 1, PhaseStep.PRECOMBAT_MAIN, playerB, "Cast " + pathToExile, false); + + execute(); + + assertPermanentCount(playerA, archonOfAbsolution, 1); + } }