コード例 #1
0
        public void GetNumberArr_CreatesArray_True()
        {
            PingPongGenerator newPong = new PingPongGenerator(5);
            List <int>        result  = newPong.GetNumberArr();

            CollectionAssert.AreEqual(result, new List <int>()
            {
                1, 2, 3, 4, 5
            });
        }
コード例 #2
0
        public void DoPingPong_Combine_GetNumberArr_ChangeNumberToString_True()
        {
            List <string> newResult = new List <string>()
            {
                "1", "2", "Ping", "4", "Pong", "Ping"
            };
            PingPongGenerator newPong      = new PingPongGenerator(5);
            List <int>        numArr       = newPong.GetNumberArr();
            List <string>     stringActual = newPong.DoPingPong(numArr);

            Assert.AreEqual(newResult, stringActual);
        }