public void ThenTheResultShouldBeOnTheScreen(int p0) { RPNCalculator calc = new RPNCalculator(); int result = calc.MyCalc(expr); Assert.AreEqual(8, result); //ScenarioContext.Current.Pending(); }
public void MyCalcTest() { try { RPNCalculator calc = new RPNCalculator(); int result = calc.MyCalc(" "); Assert.Fail(); } catch (Exception ex) { Assert.AreEqual("Invalid Exp", ex.Message); } }