Esempio n. 1
0
        public void PrintCustomerBill()
        {
            int                      prod1 = 3434324;
            int                      prod2 = 5645434;
            MiniCalc                 mCalc = new MiniCalc();
            CommercialCalc           cCalc = new CommercialCalc();
            ScientificCalc           sCalc = new ScientificCalc();
            IArithematicOperations   calc  = new ScientificCalc();
            ITrigonametricOperations Tcalc = new ScientificCalc();
            //IWebDriver driver = new ChromeDriver();
            int bill = sCalc.Addition(prod1, prod2);

            Debug.WriteLine("Customer Bill :" + bill);
            //mCalc.DisplayMiniLogo();
            //cCalc.DisplayCommercialLogo();
            sCalc.DisplayScientificLogo();
            calc.Addition(prod1, prod2);
            Tcalc.CoSee();
        }
Esempio n. 2
0
 public void Multiplication_of_2_and_2_returns_4()
 {
     Assert.AreEqual(4, MiniCalc.Multiply(2, 2));
 }
Esempio n. 3
0
 public void Multiplication_of_2_by_2_equals_4()
 {
     Assert.IsTrue(MiniCalc.TestMyMain("2 2").Contains("2x2=4"));
 }
Esempio n. 4
0
 [Test] //Under int.MinValue
 public void Multiplication_of_int_MIN_VALUE_and_2__Throws_OverflowException()
 {
     Assert.Throws <System.OverflowException>(() => MiniCalc.Multiply(int.MinValue, 2));
 }
Esempio n. 5
0
 [Test] //Above int.MaxValue
 public void Multiplication_of_3_and_INT_MAX_VALUE_Throws_OverflowException()
 {
     Assert.Throws <System.OverflowException>(() => MiniCalc.Multiply(3, int.MaxValue));
 }
Esempio n. 6
0
 [Test] //Under int.MinValue
 public void Multiplication_of_negative_3500000_and_7589_Throws_OverflowException()
 {
     Assert.Throws <System.OverflowException>(() => MiniCalc.Multiply(-3500000, 7589));
 }
Esempio n. 7
0
 [Test] //Above int.MaxValue
 public void Multiplication_of_2_billion_and_23_Throws_System_Overflow_Exception()
 {
     Assert.Throws <System.OverflowException>(() => MiniCalc.Multiply(2000000000, 23));
 }
Esempio n. 8
0
 public void Multiplication_of_0_and_MAX_INT_returns_0()
 {
     Assert.AreEqual(0, MiniCalc.Multiply(0, int.MaxValue));
 }
Esempio n. 9
0
 public void Multiplication_of_negative_1_and_negative_50_returns_50()
 {
     Assert.AreEqual(50, MiniCalc.Multiply(-1, -50));
 }
Esempio n. 10
0
 public void Multiplication_of_negative_4_and_755_returns_negative_3020()
 {
     Assert.AreEqual(-3020, MiniCalc.Multiply(-4, 755));
 }