MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / as_currency

Method as_currency

test/ext/test_hybrid.py:2032–2037  ·  view source on GitHub ↗
(self, other_currency)

Source from the content-addressed store, hash-verified

2030 return self.amount == other.as_currency(self.currency).amount
2031
2032 def as_currency(self, other_currency):
2033 return Amount(
2034 currency_lookup[(self.currency, other_currency)]
2035 * self.amount,
2036 other_currency,
2037 )
2038
2039 def __clause_element__(self):
2040 # helper method for SQLAlchemy to interpret

Callers 11

__add__Method · 0.80
__sub__Method · 0.80
__lt__Method · 0.80
__gt__Method · 0.80
__eq__Method · 0.80
balanceMethod · 0.80
test_instance_twoMethod · 0.80
test_query_twoMethod · 0.80
test_query_threeMethod · 0.80
test_query_fourMethod · 0.80
test_query_fiveMethod · 0.80

Calls 1

AmountClass · 0.85

Tested by

no test coverage detected