예제 #1
0
 public void Rule_IsKaidan_数字違い()
 {
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C3 C4 C6")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C6 C4 C7")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C2 CQ")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C2 C3")));
 }
예제 #2
0
 public void Rule_IsKaidan_IsOK()
 {
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C3 C4 C5")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C6 C4 C5")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("CK CQ CJ")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C2 CK")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 CQ CK")));
 }
예제 #3
0
 public void Rule_IsKaidan_スート違い()
 {
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C3 D4 C5")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("D6 C4 C5")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("CK CQ HJ")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("S1 C2 CK")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 CQ DK")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 JK DK")));
 }
예제 #4
0
 public void Rule_IsKaidan_ジョーカー()
 {
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C3 C4 JK")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("JK C4 C6")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 JK CQ")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C2 JK")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C2 JK JK")));
     Assert.IsTrue(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 CJ JK JK")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C1 C3 JK")));
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C4 C2 JK")));
 }
예제 #5
0
        public void init()
        {
            this._rule = new KaidanRule();

            _ctx = ContextFactory.CreateGameContext() as GameContext;

            var p1 = new TestPlayer("test1");

            _pctx1 = ContextFactory.CreatePlayerContext(p1, _ctx);

            var p2 = new TestPlayer("test2");

            _pctx2 = ContextFactory.CreatePlayerContext(p2, _ctx);
        }
예제 #6
0
 public void Rule_IsKaidan_枚数不足()
 {
     Assert.IsFalse(KaidanRule.IsKaidan(DeckGenerator.FromCardsetString("C3 C4")));
 }