From b8b45cc9f21983c5024630491a825cd7d5f01b83 Mon Sep 17 00:00:00 2001 From: Peter Evans Date: Fri, 13 Apr 2018 23:38:00 -0500 Subject: [PATCH] We need to check if we would break ourselves --- tests/vm_debug.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/vm_debug.c b/tests/vm_debug.c index 07a3265..942f96b 100644 --- a/tests/vm_debug.c +++ b/tests/vm_debug.c @@ -266,7 +266,10 @@ Test(apple2_debug, cmd_step) cr_assert_eq(mach->cpu->PC, 1); // We should go nowhere here - mos6502_execute(mach->cpu); + if (!apple2_debug_broke(mach->cpu->PC)) { + mos6502_execute(mach->cpu); + } + cr_assert_eq(mach->cpu->PC, 1); // Step should a) unbreak at PC, b) execute at PC