Search in sources :

Example 1 with LondonMulligan

use of mage.game.mulligan.LondonMulligan in project mage by magefree.

the class SerializationTest method test_LondonMulligan.

@Test
public void test_LondonMulligan() {
    LondonMulligan mulligan = new LondonMulligan(15);
    Object compressed = CompressUtil.compress(mulligan);
    Assert.assertTrue("Must be zip", compressed instanceof ZippedObjectImpl);
    LondonMulligan uncompressed = (LondonMulligan) CompressUtil.decompress(compressed);
    Assert.assertEquals("Must be same", mulligan.getFreeMulligans(), uncompressed.getFreeMulligans());
}
Also used : ZippedObjectImpl(mage.remote.traffic.ZippedObjectImpl) LondonMulligan(mage.game.mulligan.LondonMulligan) Test(org.junit.Test)

Example 2 with LondonMulligan

use of mage.game.mulligan.LondonMulligan in project mage by magefree.

the class FreeformUnlimitedCommanderTest method test_construct_returnsFreeformPlusCommander.

@Test
public void test_construct_returnsFreeformPlusCommander() {
    // Arrange
    Mulligan mulligan = new LondonMulligan(1);
    int startLife = 40;
    // Assert
    FreeformUnlimitedCommander game = new FreeformUnlimitedCommander(MultiplayerAttackOption.MULTIPLE, RangeOfInfluence.ALL, mulligan, startLife);
    // Assert
    Assert.assertEquals(FreeformUnlimitedCommander.class, game.getClass());
}
Also used : LondonMulligan(mage.game.mulligan.LondonMulligan) Mulligan(mage.game.mulligan.Mulligan) FreeformUnlimitedCommander(mage.game.FreeformUnlimitedCommander) LondonMulligan(mage.game.mulligan.LondonMulligan) Test(org.junit.Test)

Aggregations

LondonMulligan (mage.game.mulligan.LondonMulligan)2 Test (org.junit.Test)2 FreeformUnlimitedCommander (mage.game.FreeformUnlimitedCommander)1 Mulligan (mage.game.mulligan.Mulligan)1 ZippedObjectImpl (mage.remote.traffic.ZippedObjectImpl)1