示例#1
0
 def test_div_operator_div_by_zero(self):
     with pytest.raises(ZeroDivisionError):
         LinExp._div_operator(LinExp(123), LinExp(0))
     with pytest.raises(ZeroDivisionError):
         LinExp._div_operator(LinExp({"a": 123}), LinExp(0))
示例#2
0
 def test_div_operator(self, a, b, exp_result):
     assert LinExp._div_operator(a, b) == exp_result