Adding targets (Part 1/3) (#13680)

Adds target and/or target adjuster to cards whose abilities have the word "target", cards A-G.
Creates SourceDealsNoncombatDamageToOpponentTriggeredAbility and DefineByTriggerTargetAdjuster
This commit is contained in:
ssk97 2025-06-17 22:35:49 -07:00 committed by GitHub
parent 6d3bd7a19f
commit 9ce5dd212a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
25 changed files with 355 additions and 729 deletions

View file

@ -0,0 +1,41 @@
package org.mage.test.cards.single.otc;
import mage.constants.PhaseStep;
import mage.constants.Zone;
import org.junit.Test;
import org.mage.test.serverside.base.CardTestPlayerBase;
public class BladegriffPrototypeTest extends CardTestPlayerBase {
private static final String griff = "Bladegriff Prototype";
@Test
public void test_CanTargetOwn() {
setStrictChooseMode(true);
addCard(Zone.BATTLEFIELD, playerB, "Squire");
addCard(Zone.BATTLEFIELD, playerA, griff);
attack(1, playerA, griff);
addTarget(playerB, "Squire");
setStopAt(1, PhaseStep.END_COMBAT);
execute();
assertGraveyardCount(playerB, "Squire", 1);
}
@Test(expected=AssertionError.class)
public void test_CantTargetYours() {
setStrictChooseMode(true);
addCard(Zone.BATTLEFIELD, playerB, "Squire");
addCard(Zone.BATTLEFIELD, playerA, griff);
attack(1, playerA, griff);
addTarget(playerB, griff);
setStopAt(1, PhaseStep.END_COMBAT);
execute();
}
}