Merge pull request #3624 from moodyjon/test_fix_exch_rate1
Fixes for intermittent test failures: test_exchange_rate_manager(), test_basic_claim_search()
This commit is contained in:
commit
87b4404767
2 changed files with 2 additions and 2 deletions
|
@ -208,7 +208,7 @@ class ClaimSearchCommand(ClaimTestCase):
|
||||||
# resolve by sd hash
|
# resolve by sd hash
|
||||||
two_sd_hash = two['outputs'][0]['value']['source']['sd_hash']
|
two_sd_hash = two['outputs'][0]['value']['source']['sd_hash']
|
||||||
await self.assertFindsClaims([two], sd_hash=two_sd_hash)
|
await self.assertFindsClaims([two], sd_hash=two_sd_hash)
|
||||||
await self.assertFindsClaims([two], sd_hash=two_sd_hash[:2])
|
await self.assertFindsClaims([two], sd_hash=two_sd_hash[:4])
|
||||||
|
|
||||||
async def test_source_filter(self):
|
async def test_source_filter(self):
|
||||||
channel = await self.channel_create('@abc')
|
channel = await self.channel_create('@abc')
|
||||||
|
|
|
@ -24,7 +24,7 @@ class TestExchangeRateManager(AsyncioTestCase):
|
||||||
self.assertLessEqual(len(failures), 1, f"feed failures: {failures}. Please check exchange rate feeds!")
|
self.assertLessEqual(len(failures), 1, f"feed failures: {failures}. Please check exchange rate feeds!")
|
||||||
lbc = manager.convert_currency('USD', 'LBC', Decimal('1.0'))
|
lbc = manager.convert_currency('USD', 'LBC', Decimal('1.0'))
|
||||||
self.assertGreaterEqual(lbc, 2.0)
|
self.assertGreaterEqual(lbc, 2.0)
|
||||||
self.assertLessEqual(lbc, 80.0)
|
self.assertLessEqual(lbc, 120.0)
|
||||||
lbc = manager.convert_currency('BTC', 'LBC', Decimal('0.01'))
|
lbc = manager.convert_currency('BTC', 'LBC', Decimal('0.01'))
|
||||||
self.assertGreaterEqual(lbc, 1_000)
|
self.assertGreaterEqual(lbc, 1_000)
|
||||||
self.assertLessEqual(lbc, 30_000)
|
self.assertLessEqual(lbc, 30_000)
|
||||||
|
|
Loading…
Reference in a new issue