Ejemplo n.º 1
0
        public void BuildNavigation_WhenCurrentPage10_AddControls()
        {
            // Arrange
            var tableCell = new Moq.Mock <TableCell>();

            tableCell.Setup(x => x.Controls).Returns(new ControlCollection(new Control()));
            SetUp("y");

            // Act
            _privateObject.Invoke("BuildNavigation", tableCell.Object);

            // Assert
            tableCell.ShouldSatisfyAllConditions(
                () => tableCell.Object.Controls.Count.ShouldBe(34),
                () => tableCell.Object.ClientID.ShouldBe(null),
                () => tableCell.Object.Page.ShouldBe(null));
        }