From 3810a6230d84d1b31b4d57b515565c35102c9e61 Mon Sep 17 00:00:00 2001 From: Oleg Agafonov Date: Tue, 28 Jul 2020 03:59:52 +0400 Subject: [PATCH] Tests: fixed random fail (if player got Entreat the Dead on the draw) --- Mage.Tests/ReyhanCommanderDeck.dck | 65 ------------------- .../duel/CastBGPartnerCommanderTest.java | 24 +++---- 2 files changed, 10 insertions(+), 79 deletions(-) delete mode 100644 Mage.Tests/ReyhanCommanderDeck.dck diff --git a/Mage.Tests/ReyhanCommanderDeck.dck b/Mage.Tests/ReyhanCommanderDeck.dck deleted file mode 100644 index 2da832153e..0000000000 --- a/Mage.Tests/ReyhanCommanderDeck.dck +++ /dev/null @@ -1,65 +0,0 @@ -2 [C18:134] Budoka Gardener -2 [C18:136] Consign to Dust -1 [C18:129] Avenger of Zendikar -1 [C18:29] Crash of Rhino Beetles -1 [C18:119] Stitch Together -1 [C18:116] Retreat to Hagra -1 [C18:16] Loyal Subordinate -1 [C18:15] Entreat the Dead -1 [C18:117] Ruinous Path -1 [C18:114] Moonlight Bargain -1 [C18:18] Skull Storm -1 [C18:115] Phyrexian Delver -1 [C18:14] Bloodtracker -1 [C18:19] Sower of Discord -1 [C18:17] Night Incarnate -1 [C18:113] Army of the Damned -1 [C18:118] Soul of Innistrad -1 [C18:197] Blinkmoth Urn -1 [C18:54] Coveted Jewel -1 [C18:199] Chief of the Foundry -1 [C18:217] Psychosis Crawler -1 [C18:202] Darksteel Juggernaut -1 [C18:226] Thopter Assembly -1 [C18:224] Steel Hellkite -1 [C18:222] Sol Ring -1 [C18:219] Scuttling Doom Engine -1 [C18:205] Duplicant -1 [C18:212] Myr Battlesphere -1 [C18:53] Ancient Stone Idol -1 [C18:223] Soul of New Phyrexia -1 [C18:160] Sakura-Tribe Elder -1 [C18:133] Borderland Explorer -1 [C18:146] Farhaven Elf -1 [C18:128] Aura Gnarlid -1 [C18:166] Yavimaya Elder -1 [C18:167] Yavimaya Enchantress -1 [C18:161] Scute Mob -1 [C18:151] Herald of the Pantheon -1 [C18:35] Turntimber Sower -1 [C18:34] Ravenous Slime -1 [C18:140] Eidolon of Blossoms -1 [C18:135] Centaur Vinecrasher -1 [C18:156] Moldgraf Monstrosity -1 [C18:149] Ground Seal -1 [C18:147] Fertile Ground -1 [C18:162] Snake Umbra -1 [C18:157] Overgrowth -1 [C18:150] Harrow -1 [C18:138] Cultivate -1 [C18:164] Vow of Wildness -1 [C18:152] Hunting Wilds -1 [C18:144] Explosive Vegetation -1 [C18:131] Bear Umbra -1 [C18:32] Myth Unbound -1 [C18:141] Enchantress's Presence -1 [C18:142] Epic Proportions -1 [C18:137] Creeping Renaissance -1 [C18:30] Genesis Storm -1 [C18:163] Spawning Grounds -25 [PPP1:5] Forest -12 [PPP1:3] Swamp -SB: 1 [CM2:13] Reyhan, Last of the Abzan -SB: 1 [CM2:11] Ikra Shidiqi, the Usurper -LAYOUT MAIN:(2,11)(CMC,true,29)|()()([C18:134])([C18:16],[C18:199])([C18:14])([C18:29],[C18:115],[C18:17],[C18:217],[C18:202],[C18:161],[C18:151],[C18:134],[C18:35],[C18:140],[C18:135],[C18:156])([C18:19],[C18:118],[C18:226],[C18:224],[C18:219],[C18:205],[C18:223],[C18:149],[C18:147],[C18:162],[C18:34],[C18:157],[C18:150],[C18:138],[C18:164],[C18:152],[C18:144],[C18:136],[C18:131],[C18:32],[C18:141],[C18:142],[C18:137],[C18:30],[C18:163])([C18:129],[C18:212],[C18:160],[C18:133],[C18:146],[C18:128],[C18:166],[C18:167])()()([C18:53])([PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:5],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3],[PPP1:3])([C18:222])([C18:119])([C18:136],[C18:116],[C18:15],[C18:117])()([C18:114],[C18:197])([C18:54])()([C18:113])([C18:18])() -LAYOUT SIDEBOARD:(1,2)(RARITY,true,0)|([CM2:13])([CM2:11]) diff --git a/Mage.Tests/src/test/java/org/mage/test/commander/duel/CastBGPartnerCommanderTest.java b/Mage.Tests/src/test/java/org/mage/test/commander/duel/CastBGPartnerCommanderTest.java index 29dca3ceef..37054c54f0 100644 --- a/Mage.Tests/src/test/java/org/mage/test/commander/duel/CastBGPartnerCommanderTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/commander/duel/CastBGPartnerCommanderTest.java @@ -1,27 +1,15 @@ package org.mage.test.commander.duel; -import java.io.FileNotFoundException; import mage.constants.PhaseStep; import mage.constants.Zone; -import mage.game.Game; -import mage.game.GameException; import org.junit.Test; import org.mage.test.serverside.base.CardTestCommanderDuelBase; /** - * - * @author LevelX2 ReyhanCommanderDeck + * @author LevelX2 */ public class CastBGPartnerCommanderTest extends CardTestCommanderDuelBase { - @Override - protected Game createNewGameAndPlayers() throws GameException, FileNotFoundException { - setDecknamePlayerA("ReyhanCommanderDeck.dck"); // Commander Reyhan, Last of the Abzan {1}{B}{G} - // + Ikra Shidiqi, the Usurper - setDecknamePlayerB("CommanderDuel_UW.dck"); // Commander = Daxos of Meletis - return super.createNewGameAndPlayers(); - } - /** * With commander rule changes 6/2020 Reyhan goes to exile first before it * goes to command zone. So it's triggerd ability does no longer move the @@ -29,6 +17,10 @@ public class CastBGPartnerCommanderTest extends CardTestCommanderDuelBase { */ @Test public void testExileReyhan() { + addCard(Zone.COMMAND, playerA, "Reyhan, Last of the Abzan", 1); + addCard(Zone.COMMAND, playerA, "Ikra Shidiqi, the Usurper", 1); + addCard(Zone.COMMAND, playerB, "Daxos of Meletis", 1); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 1); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); @@ -63,6 +55,10 @@ public class CastBGPartnerCommanderTest extends CardTestCommanderDuelBase { @Test public void testCastBothPartnerCommanders() { + addCard(Zone.COMMAND, playerA, "Reyhan, Last of the Abzan", 1); + addCard(Zone.COMMAND, playerA, "Ikra Shidiqi, the Usurper", 1); + addCard(Zone.COMMAND, playerB, "Daxos of Meletis", 1); + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 3); @@ -70,7 +66,7 @@ public class CastBGPartnerCommanderTest extends CardTestCommanderDuelBase { // Whenever a creature you control dies or is put into the command zone, // if it had one or more +1/+1 counters on it, you may put that many +1/+1 counters on target creature. // Partner (You can have two commanders if both have partner.) - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Reyhan, Last of the Abzan"); // Creature 0/0 + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Reyhan, Last of the Abzan"); // {1}{B}{G} Creature 0/0 // Menace // Whenever a creature you control deals combat damage to a player, you gain life equal to that creature's toughness.