Accord.Tests.Math.MatrixTest.ApplyTest1 C# (CSharp) Method

ApplyTest1() private method

private ApplyTest1 ( ) : void
return void
        public void ApplyTest1()
        {
            int[,] matrix = 
            {
                { 1, 2, 3 },
                { 4, 5, 6 }
            };

            Func<int, int, int, string> func =
                (x, i, j) => "Element at (" + i + "," + j + ") is " + x;

            string[,] expected =
            {
                { "Element at (0,0) is 1", "Element at (0,1) is 2", "Element at (0,2) is 3" },
                { "Element at (1,0) is 4", "Element at (1,1) is 5", "Element at (1,2) is 6" },
            };

            string[,] actual = Matrix.ApplyWithIndex(matrix, func);

            Assert.IsTrue(expected.IsEqual(actual));
        }
MatrixTest