def test_blockchain_is_valid_schema_invalid(self): err_message = '[Blockchain] Validation error.' with self.assertRaises(BlockchainError) as err: Blockchain.is_valid(self.invalid_chain) self.assertIsInstance(err, BlockchainError) self.assertIn(err_message, err.message)
def test_blockchain_is_valid_schema_valid(self): Blockchain.is_valid(self.valid_chain)