コード例 #1
0
        public void ShouldCalculateGcdExtendedResults(GcdFinderTestCase testCase)
        {
            // When
            var result = _gcdFinder.GcdExtended(testCase.A, testCase.B);

            //Then
            Assert.Equal(testCase.Expected, result.Gcd);
            Assert.Equal(testCase.Expected, testCase.A * result.X + testCase.B * result.Y);
        }
コード例 #2
0
 public void ShouldCalculateGcd(GcdFinderTestCase testCase)
 {
     Assert.Equal(testCase.Expected, _gcdFinder.Gcd(testCase.A, testCase.B));
 }