Skip to content
Snippets Groups Projects
Commit b9dabbbd authored by vincent's avatar vincent
Browse files

Tests:

	* Set a timeout for the symbolic execution
	* More tests for the symbolic execution
parent f85da99d
No related branches found
No related tags found
No related merge requests found
This diff is collapsed.
......@@ -9,7 +9,9 @@ from symbolic_execution.hardware.machines.btc_machine import BTC_VECTOR_SIZE, BT
from symbolic_execution.program.executer.concrete import ConcreteExecuter
from .concrete.testing_scenarii import TESTING_SCENARII as CONCRETE_TESTING_SCENARII
from .symbolic.testing_scenarii import TESTING_SCENARII as SYMBOLIC_TESTING_SCENARII
from symbolic_execution.language.bitcoin.symbolic_interpreter import find_unlocking_script
from symbolic_execution.language.bitcoin.symbolic_interpreter import (
find_unlocking_script,
)
from z3 import is_expr
......@@ -90,7 +92,7 @@ class TestParser(unittest.TestCase):
def test_symbolic_execution(self):
for _, scenario in enumerate(SYMBOLIC_TESTING_SCENARII):
with self.subTest(scenario.hex_script):
_, status = find_unlocking_script(scenario.hex_script)
_, status = find_unlocking_script(scenario.hex_script, timeout=10)
self.assertEqual(status, scenario.execution_status)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment