public void TestMethodCalculateString() { string str = "(5+3)^3*2+2.7-8÷2"; string expected = "1022.7"; string actual = ScientificCalc.CalculateString(str); Assert.AreEqual(expected, actual); }
public void TestMethodFactorial() { long num = 17; long expected = 355687428096000; long actual = ScientificCalc.Factorial(num); Assert.AreEqual(expected, actual); }
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(); }
private void buttonN_Click(object sender, EventArgs e) { buttonEquals.PerformClick(); display.Text = ScientificCalc.Factorial(Convert.ToInt64(display.Text)).ToString(); }
private void equals_ClickScientific(object sender, EventArgs e) { display.Text = ScientificCalc.CalculateString(display.Text); }