From 7d22bfffa5e98b6144f24988b5cb36e06c515fb6 Mon Sep 17 00:00:00 2001 From: Jack Date: Thu, 28 Jul 2016 02:30:37 -0400 Subject: [PATCH] fee tests --- tests/lbrynet/core/test_LBRYMetadata.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tests/lbrynet/core/test_LBRYMetadata.py b/tests/lbrynet/core/test_LBRYMetadata.py index 643fc5d31..e3910ed1a 100644 --- a/tests/lbrynet/core/test_LBRYMetadata.py +++ b/tests/lbrynet/core/test_LBRYMetadata.py @@ -8,12 +8,12 @@ class LBRYFeeFormatTest(unittest.TestCase): def test_fee_created_with_correct_inputs(self): fee_dict = { 'USD': { - 'amount': 10, - 'address': None + 'amount': 10.0, + 'address': "bRcHraa8bYJZL7vkh5sNmGwPDERFUjGPP9" } } fee = LBRYMetadata.LBRYFeeValidator(fee_dict) - self.assertEqual(10, fee['USD']['amount']) + self.assertEqual(10.0, fee['USD']['amount']) class LBRYFeeTest(unittest.TestCase): @@ -28,13 +28,13 @@ class LBRYFeeTest(unittest.TestCase): def test_fee_converts_to_lbc(self): fee_dict = { 'USD': { - 'amount': 10, - 'address': None + 'amount': 10.0, + 'address': "bRcHraa8bYJZL7vkh5sNmGwPDERFUjGPP9" } } - rates = {'BTCLBC': {'spot': 3, 'ts': 2}, 'USDBTC': {'spot': 2, 'ts': 3}} + rates = {'BTCLBC': {'spot': 3.0, 'ts': 2}, 'USDBTC': {'spot': 2.0, 'ts': 3}} fee = LBRYMetadata.LBRYFee(fee_dict, rates, 0) - self.assertEqual(60, fee.to_lbc()) + self.assertEqual(60.0, fee.to_lbc()) class MetadataTest(unittest.TestCase):