diff --git a/SabberStoneCore/CardSets/Standard/Expert1CardsGen.cs b/SabberStoneCore/CardSets/Standard/Expert1CardsGen.cs index 137044ced..9b53ac8b6 100644 --- a/SabberStoneCore/CardSets/Standard/Expert1CardsGen.cs +++ b/SabberStoneCore/CardSets/Standard/Expert1CardsGen.cs @@ -3426,13 +3426,15 @@ private static void Warrior(IDictionary> cards) // - REQ_TARGET_TO_PLAY = 0 // -------------------------------------------------------- cards.Add("EX1_391", new List { - // TODO [EX1_391] Slam && Test: Slam_EX1_391 - new Enchantment - { - Activation = EnchantmentActivation.SPELL, - SingleTask = null, - }, - }); + new Enchantment + { + Activation = EnchantmentActivation.SPELL, + SingleTask = ComplexTask.Create( + new DamageTask(2, EntityType.TARGET, true), + new SelfConditionTask(EntityType.TARGET, SelfCondition.IsNotDead), + new FlagTask(true, new DrawTask())) + }, + }); // ---------------------------------------- SPELL - WARRIOR // [EX1_392] Battle Rage - COST:2 diff --git a/SabberStoneXTest/Expert1CardsGenTest.cs b/SabberStoneXTest/Expert1CardsGenTest.cs index 411a40dd7..2136a3ad0 100644 --- a/SabberStoneXTest/Expert1CardsGenTest.cs +++ b/SabberStoneXTest/Expert1CardsGenTest.cs @@ -4169,20 +4169,19 @@ public void Rampage_CS2_104() Assert.Equal(7, ((Minion)minion1).Health); } - // ---------------------------------------- SPELL - WARRIOR - // [EX1_391] Slam - COST:2 - // - Fac: neutral, Set: expert1, Rarity: common - // -------------------------------------------------------- - // Text: Deal $2 damage to a minion. If it survives, draw a card. *spelldmg - // -------------------------------------------------------- - // PlayReq: - // - REQ_MINION_TARGET = 0 - // - REQ_TARGET_TO_PLAY = 0 - // -------------------------------------------------------- - [Fact(Skip="NotImplemented")] + // ---------------------------------------- SPELL - WARRIOR + // [EX1_391] Slam - COST:2 + // - Fac: neutral, Set: expert1, Rarity: common + // -------------------------------------------------------- + // Text: Deal $2 damage to a minion. If it survives, draw a card. *spelldmg + // -------------------------------------------------------- + // PlayReq: + // - REQ_MINION_TARGET = 0 + // - REQ_TARGET_TO_PLAY = 0 + // -------------------------------------------------------- + [Fact] public void Slam_EX1_391() { - // TODO Slam_EX1_391 test var game = new Game(new GameConfig { StartPlayer = 1, @@ -4193,8 +4192,13 @@ public void Slam_EX1_391() game.StartGame(); game.Player1.BaseMana = 10; game.Player2.BaseMana = 10; - //var testCard = Generic.DrawCard(game.CurrentPlayer,Cards.FromName("Slam")); - } + var testCard = Generic.DrawCard(game.CurrentPlayer,Cards.FromName("Slam")); + var minion = Generic.DrawCard(game.CurrentPlayer, Cards.FromName("Chillwind Yeti")); + game.Process(PlayCardTask.Minion(game.CurrentPlayer, minion)); + Assert.Equal(5, game.CurrentPlayer.Hand.Count); + game.Process(PlayCardTask.SpellTarget(game.CurrentPlayer, testCard, minion)); + Assert.Equal(5, game.CurrentPlayer.Hand.Count); + } // ---------------------------------------- SPELL - WARRIOR // [EX1_392] Battle Rage - COST:2