MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / assert_approx

Function assert_approx

test/functional/wallet_groups.py:13–17  ·  view source on GitHub ↗
(v, vexp, vspan=0.00001)

Source from the content-addressed store, hash-verified

11)
12
13def assert_approx(v, vexp, vspan=0.00001):
14 if v < vexp - vspan:
15 raise AssertionError("%s < [%s..%s]" % (str(v), str(vexp - vspan), str(vexp + vspan)))
16 if v > vexp + vspan:
17 raise AssertionError("%s > [%s..%s]" % (str(v), str(vexp - vspan), str(vexp + vspan)))
18
19class WalletGroupTest(BitcoinTestFramework):
20 def set_test_params(self):

Callers 1

run_testMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected