diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2015-12-01 11:04:31 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2015-12-01 11:04:32 +0100 |
commit | 6abf6eb7bb777a5c4f22e9db6d4544281277378f (patch) | |
tree | ba37c620f048832f3a2830b7149afe48e603c5c5 /qa/rpc-tests/test_framework/util.py | |
parent | 8f761e87c3fd0ad50d41925d8c2ac2c429403b44 (diff) | |
parent | 2b31ab90c4ca1e1a7037ad02424ac51b6b86160c (diff) |
Merge pull request #7063
2b31ab9 Add rpc test for prioritisetransaction (Suhas Daftuar)
6e8b07f Add rounding helper function to util.py (Suhas Daftuar)
Diffstat (limited to 'qa/rpc-tests/test_framework/util.py')
-rw-r--r-- | qa/rpc-tests/test_framework/util.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/qa/rpc-tests/test_framework/util.py b/qa/rpc-tests/test_framework/util.py index d9d5129f21..1a526ae06e 100644 --- a/qa/rpc-tests/test_framework/util.py +++ b/qa/rpc-tests/test_framework/util.py @@ -404,3 +404,6 @@ def assert_raises(exc, fun, *args, **kwds): raise AssertionError("Unexpected exception raised: "+type(e).__name__) else: raise AssertionError("No exception raised") + +def satoshi_round(amount): + return Decimal(amount).quantize(Decimal('0.00000001'), rounding=ROUND_DOWN) |