示例#1
0
        public void PaperAlwaysDrawsPaper()
        {
            IPlayer player1 = new PaperPlayer();
            IPlayer player2 = new PaperPlayer();

            RockPaperScissorsGame game = new RockPaperScissorsGame(player1, player2);

            Outcome result = game.Play();

            Assert.AreEqual(Outcome.Draw, result);
        }
示例#2
0
        public void ScissorsAlwaysBeatsPaper()
        {
            IPlayer player1 = new ScissorsPlayer();
            IPlayer player2 = new PaperPlayer();

            RockPaperScissorsGame game = new RockPaperScissorsGame(player1, player2);

            Outcome result = game.Play();

            Assert.AreEqual(Outcome.Player1Wins, result);
        }