示例#1
0
        public void UsageTest()
        {
            Card x;

            x = new Attack(CardSuit.Club, 0);
            Assert.AreEqual(1, x.numOfTargets());
            x = new Miss(CardSuit.Club, 0);
            Assert.AreEqual(-1, x.numOfTargets()); // this means not usable
            x = new Wine(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new Peach(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new Negate(CardSuit.Club, 0);
            Assert.AreEqual(-1, x.numOfTargets());
            x = new Barbarians(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new HailofArrow(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new PeachGarden(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new Wealth(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new Steal(CardSuit.Club, 0);
            Assert.AreEqual(1, x.numOfTargets());
            x = new Break(CardSuit.Club, 0);
            Assert.AreEqual(1, x.numOfTargets());
            x = new Capture(CardSuit.Club, 0);
            Assert.AreEqual(1, x.numOfTargets());
            x = new Starvation(CardSuit.Club, 0);
            Assert.AreEqual(1, x.numOfTargets());
            x = new Crossbow(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new IceSword(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new Scimitar(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new BlackShield(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
            x = new EightTrigrams(CardSuit.Club, 0);
            Assert.AreEqual(0, x.numOfTargets());
        }