mirror of
https://github.com/correl/mage.git
synced 2024-12-24 11:50:45 +00:00
Test for AI that reproduces the case when useful "may" ability isn't used.
This commit is contained in:
parent
af05af7050
commit
41f0fecd6e
1 changed files with 32 additions and 0 deletions
|
@ -0,0 +1,32 @@
|
|||
package org.mage.test.ai;
|
||||
|
||||
import junit.framework.Assert;
|
||||
import mage.Constants;
|
||||
import mage.game.permanent.Permanent;
|
||||
import org.junit.Test;
|
||||
import org.mage.test.serverside.base.CardTestBase;
|
||||
|
||||
/**
|
||||
* @author ayratn
|
||||
*/
|
||||
public class NimShamblerTest extends CardTestBase {
|
||||
|
||||
/**
|
||||
* Reproduces the bug when AI sacrifices its creatures for no reason.
|
||||
*/
|
||||
@Test
|
||||
public void testNoCreatureWasSacrificed() {
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Nim Shambler");
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerA, "Blood Cultist");
|
||||
addCard(Constants.Zone.BATTLEFIELD, playerB, "Ob Nixilis, the Fallen");
|
||||
|
||||
execute();
|
||||
|
||||
Permanent nimShambler = getPermanent("Nim Shambler", playerA.getId());
|
||||
Assert.assertNotNull(nimShambler);
|
||||
|
||||
Permanent bloodCultist = getPermanent("Blood Cultist", playerA.getId());
|
||||
Assert.assertNotNull(bloodCultist);
|
||||
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue