コード例 #1
0
ファイル: UnitTest1.cs プロジェクト: femiola12/Solutions
        public void RabbitGrowthTest(int totalYears, int expectedRabbitAge, int expectedRabbitCount)
        {
            (int actualCumulativeAge, int actualRabbitCount) = Rabbit_Collection.MultiplyRabbits(totalYears);

            Assert.AreEqual(expectedRabbitAge, actualCumulativeAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: hematshah/Labs
        public void RabbitGrowthAfterachedAtTheAgeOfThreeTests(int totalYears, int expectedRabbitAge, int expectedRabbitCount)
        {
            // Arrange

            //Act
            (int actualCumulativeRabbitAge, int actualRabbitCount) = Rabbit_Collection.MultiplyRabbitsAfterAgeThreeReached(totalYears);
            //Assert
            Assert.AreEqual(expectedRabbitAge, actualCumulativeRabbitAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }
コード例 #3
0
ファイル: Program.cs プロジェクト: NathanSparta1/Labs
        // [TestCase(3,-1,-1)]
        public void RabbitGrowthAfter3years(int totalYears, int expectedCumalitiveRabbitAge, int expectedRabbitCount)
        {
            //Arange

            //Act
            (int actualCumalitiveAge, int actualRabbitCount) = Rabbit_Collection.MultipleRabbits(totalYears); // tuple (int Name,int Name)

            //Assert
            Assert.AreEqual(expectedCumalitiveRabbitAge, actualCumalitiveAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }
コード例 #4
0
        public void RabbitGrowthTestsIfAgeGreaterThanTwo(int totalYears, int expectedCumulativeRabbitAge, int expectedRabbitCount)
        {
            // Arrange

            // Act
            // Tuple (int name, int name)
            (int actualCumulativeAge, int actualRabbitCount) = Rabbit_Collection.MultiplyRabbitsIfAgeGreaterThanTwo(totalYears);

            // Assert
            Assert.AreEqual(expectedCumulativeRabbitAge, actualCumulativeAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }
コード例 #5
0
ファイル: UnitTest1.cs プロジェクト: JakeHamiltonVGT/Labs
        public void RabbitGrowthTests(int totalYears, int expectedRabbitAge, int expectedRabbitCount)
        {
            // Arrange

            // Act
            // Tuple (int NAME,int NAME)
            (int actualCumulativeAge, int actualRabbitCount) = Rabbit_Collection.MultiplyRabbits(totalYears);

            // Assert
            Assert.AreEqual(expectedRabbitAge, actualCumulativeAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }
コード例 #6
0
ファイル: UnitTest1.cs プロジェクト: JakeHamiltonVGT/Labs
        public void MultiplyRabbitAfterAgeReachedThreeTest(int totalYears, int expectedRabbitAge, int expectedRabbitCount)
        {
            // Arrange
            // Create Instance in here if not static

            // Act
            // Tuple (int NAME, int NAME)
            (int actualRabbitAge, int actualRabbitCount) = Rabbit_Collection.MultiplyRabbitsAfterAgeThreeReached(totalYears);

            // Assert
            Assert.AreEqual(expectedRabbitAge, actualRabbitAge);
            Assert.AreEqual(expectedRabbitCount, actualRabbitCount);
        }