예제 #1
0
파일: Program.cs 프로젝트: djvorr/SSE
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            /*Application.Run(new Board());*/

            Game game = new Game();
            game.main();
        }
예제 #2
0
파일: UnitTest2.cs 프로젝트: djvorr/SSE
        public void TestGame()
        {
            Game game = new Game();

            game.deal();
            game.seatPlayers();

            Table table = game.getTable();

            Seat s = table.takeTurn();
            Assert.AreEqual(s.GetType(), typeof(Player), "Player not loaded into seat.");
            Assert.IsTrue(s.hand.getCards().Count > 1, "Player cards not loaded.");
            Assert.IsFalse(table.noMoreTurns(), "Detected no more turns.");

            s = table.takeTurn();
            Assert.AreEqual(s.GetType(), typeof(CPU), "CPU not loaded into seat.");
            Assert.IsTrue(s.hand.getCards().Count > 1, "CPU cards not loaded.");
        }