Example #1
0
 def test_repr(self):
     assert repr(MoneyLocalizeNode(Money(5, 'EUR'))) == '<MoneyLocalizeNode 5 EUR>'
Example #2
0
 def test_invalid_instance(self):
     with pytest.raises(Exception) as exc:
         MoneyLocalizeNode(Money(5, 'EUR'), amount=15)
     assert str(exc.value) == 'You can define either "money" or the "amount" and "currency".'
Example #3
0
 def test_repr(self):
     assert repr(MoneyLocalizeNode(Money(
         5, "EUR"))) == "<MoneyLocalizeNode 5 EUR>"