Пример #1
0
 def test_success(self):
   num1 = calculator.input1(self.mock_input1)
   oper = calculator.inputop(self.mock_operator)
   num2 = calculator.input2(self.mock_input2)
   ans = calculator.operator(num1,oper,num2)
   final = calculator.output(num1,oper,num2,ans)
   self.assertEqual(final,"1 + 1 = 2")
Пример #2
0
 def test_Output(self):
   self.assertEqual(calculator.output(10,'/',10,1),'10 / 10 = 1')