1
0
mirror of https://github.com/pevans/erc-c.git synced 2024-06-10 14:29:30 +00:00

The debug_break check was moved outside of the mos6502_execute function

This commit is contained in:
Peter Evans 2018-04-13 23:34:28 -05:00
parent 04e72486f1
commit 3834c1e112

View File

@ -194,11 +194,22 @@ Test(apple2_debug, break)
mos6502_set(mach->cpu, 2, 0xEA);
mos6502_set(mach->cpu, 3, 0xEA);
mos6502_execute(mach->cpu);
if (!apple2_debug_broke(mach->cpu->PC)) {
mos6502_execute(mach->cpu);
}
cr_assert_eq(mach->cpu->PC, 1);
mos6502_execute(mach->cpu);
if (!apple2_debug_broke(mach->cpu->PC)) {
mos6502_execute(mach->cpu);
}
cr_assert_eq(mach->cpu->PC, 2);
mos6502_execute(mach->cpu);
if (!apple2_debug_broke(mach->cpu->PC)) {
mos6502_execute(mach->cpu);
}
cr_assert_eq(mach->cpu->PC, 2);
}