def test_repr(self): assert repr(MoneyLocalizeNode(Money(5, 'EUR'))) == '<MoneyLocalizeNode 5 EUR>'
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".'
def test_repr(self): assert repr(MoneyLocalizeNode(Money( 5, "EUR"))) == "<MoneyLocalizeNode 5 EUR>"