Fixed npe of tests.

This commit is contained in:
LevelX2 2016-07-12 20:00:16 +02:00
parent e7014f385b
commit 6b635d9b8c

View file

@ -988,11 +988,11 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement
public void castSpell(int turnNum, PhaseStep step, TestPlayer player, String cardName, String targetName, String spellOnStack, StackClause clause) {
if (StackClause.WHILE_ON_STACK.equals(clause)) {
player.addAction(turnNum, step, "activate:Cast " + cardName
+ "$" + (targetName.startsWith("target") ? targetName : "target=" + targetName)
+ "$" + (targetName != null && targetName.startsWith("target") ? targetName : "target=" + targetName)
+ "$spellOnStack=" + spellOnStack);
} else {
player.addAction(turnNum, step, "activate:Cast " + cardName
+ "$" + (targetName.startsWith("target") ? targetName : "target=" + targetName)
+ "$" + (targetName != null && targetName.startsWith("target") ? targetName : "target=" + targetName)
+ "$!spellOnStack=" + spellOnStack);
}
}