Esempio n. 1
0
        public void TestApplication_IfNumber99999_ReturnsPalindromeProduct()
        {
            // Arrange
            PalindromeAlgorithm palindromeAlgorithm = new PalindromeAlgorithm();

            // Act
            this._data = this._application.GetLargestPrimePalindrome();
            long product = this._data.StoredResult;

            // Assert
            const bool expected = true;
            bool       actual   = palindromeAlgorithm.IsPalindrome(product);

            Assert.AreEqual(expected, actual);
        }
 static ApplicationController()
 {
     _primeNumberAlgorithm = new PrimeNumberAlgorithm();
     _palindromeAlgorithm  = new PalindromeAlgorithm();
     _data = new Data();
 }
 public void Setup()
 {
     // Arrange
     _palindromeAlgorithm = new PalindromeAlgorithm();
 }