From 1a1447376b7b86149963e275d86114ff671eafb0 Mon Sep 17 00:00:00 2001 From: Holger Nahrstaedt <holger@nahrstaedt.de> Date: Fri, 16 Mar 2018 15:21:15 +0100 Subject: [PATCH] Make unit test more robust --- tests/beem/test_blockchain.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/beem/test_blockchain.py b/tests/beem/test_blockchain.py index fb21291e..8ca61782 100644 --- a/tests/beem/test_blockchain.py +++ b/tests/beem/test_blockchain.py @@ -60,7 +60,7 @@ class Testcases(unittest.TestCase): self.assertTrue(isinstance(num, int)) block = b.get_current_block() self.assertTrue(isinstance(block, Block)) - self.assertEqual(num, block.identifier) + self.assertTrue((num - block.identifier) < 2) block_time = b.block_time(block.identifier) self.assertEqual(block.time(), block_time) block_timestamp = b.block_timestamp(block.identifier) -- GitLab