GetRowHeight() public méthode

Returns the number of rows of the matrix with the largest number of rows in the specified row of the MatricesMatrix
public GetRowHeight ( int row ) : int
row int
Résultat int
        public void MatricesMatrix_GetRowHeightTest()
        {
            Matrix m1 = new Matrix(1);
            Matrix m2 = new Matrix(2);
            Matrix m3 = new Matrix(3);
            Matrix m4 = new Matrix(4);

            MatricesMatrix testMatricesMatrix = new MatricesMatrix(2, 2);

            testMatricesMatrix.SetElement(0, 0, m1);
            testMatricesMatrix.SetElement(0, 1, m3);
            testMatricesMatrix.SetElement(1, 0, m2);
            testMatricesMatrix.SetElement(1, 1, m4);

            int expectedResult1 = 3;
            int expectedResult2 = 4;

            int actualResult1 = testMatricesMatrix.GetRowHeight(0);
            int actualResult2 = testMatricesMatrix.GetRowHeight(1);

            (actualResult1 == expectedResult1).Should().BeTrue();
            (actualResult2 == expectedResult2).Should().BeTrue();


        }