diff options
Diffstat (limited to 'test')
| -rw-r--r-- | test/jitter/mem_breakpoint.py | 3 | ||||
| -rw-r--r-- | test/jitter/test_post_instr.py | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/test/jitter/mem_breakpoint.py b/test/jitter/mem_breakpoint.py index 8a5d69c5..bd51e692 100644 --- a/test/jitter/mem_breakpoint.py +++ b/test/jitter/mem_breakpoint.py @@ -6,6 +6,7 @@ from miasm.analysis.machine import Machine from miasm.jitter.csts import PAGE_READ, PAGE_WRITE, \ EXCEPT_BREAKPOINT_MEMORY, EXCEPT_ACCESS_VIOL from miasm.core.locationdb import LocationDB +from miasm.jitter.jitload import JitterException def mem_breakpoint_handler(jitter): print("======") @@ -79,6 +80,6 @@ jitter.init_run(0xFFFFFF800901EBEC) try: jitter.continue_run() -except AssertionError: +except JitterException: assert jitter.vm.get_exception() == EXCEPT_ACCESS_VIOL diff --git a/test/jitter/test_post_instr.py b/test/jitter/test_post_instr.py index 16e51830..5a690e6b 100644 --- a/test/jitter/test_post_instr.py +++ b/test/jitter/test_post_instr.py @@ -6,6 +6,7 @@ from miasm.analysis.machine import Machine from miasm.jitter.csts import PAGE_READ, PAGE_WRITE, \ EXCEPT_BREAKPOINT_MEMORY, EXCEPT_ACCESS_VIOL from miasm.core.locationdb import LocationDB +from miasm.jitter.jitload import JitterException machine = Machine("x86_32") loc_db = LocationDB() @@ -45,5 +46,5 @@ jitter.vm.add_memory_breakpoint(0x11000-4, 4, PAGE_READ | PAGE_WRITE) jitter.init_run(0x1000) try: jitter.continue_run() -except AssertionError: +except JitterException: assert jitter.vm.get_exception() == EXCEPT_ACCESS_VIOL |