Add SUBC jsmoo tests

old-bit-manip
Nick Krichevsky 2023-05-05 00:10:02 -04:00
parent 6e62b632a3
commit 6dce7f0ead
7 changed files with 10 additions and 10 deletions

View File

@ -37,16 +37,16 @@ fn test_jsmoo_test(filename: &str) {
processor.run_next_instruction();
assert_eq!(processor.registers.a, test_case.r#final.a);
assert_eq!(processor.registers.b, test_case.r#final.b);
assert_eq!(processor.registers.c, test_case.r#final.c);
assert_eq!(processor.registers.d, test_case.r#final.d);
assert_eq!(processor.registers.e, test_case.r#final.e);
assert_eq!(processor.registers.get_raw_flag_bits(), test_case.r#final.f);
assert_eq!(processor.registers.h, test_case.r#final.h);
assert_eq!(processor.registers.l, test_case.r#final.l);
assert_eq!(processor.registers.program_counter, test_case.r#final.pc);
assert_eq!(processor.registers.stack_pointer, test_case.r#final.sp);
assert_eq!(processor.registers.a, test_case.r#final.a, "register a value was incorrect");
assert_eq!(processor.registers.b, test_case.r#final.b, "register b value was incorrect");
assert_eq!(processor.registers.c, test_case.r#final.c, "register c value was incorrect");
assert_eq!(processor.registers.d, test_case.r#final.d, "register d value was incorrect");
assert_eq!(processor.registers.e, test_case.r#final.e, "register e value was incorrect");
assert_eq!(processor.registers.get_raw_flag_bits(), test_case.r#final.f, "register f value was incorrect");
assert_eq!(processor.registers.h, test_case.r#final.h, "register h value was incorrect");
assert_eq!(processor.registers.l, test_case.r#final.l, "register l value was incorrect");
assert_eq!(processor.registers.program_counter, test_case.r#final.pc, "program counter was incorrect");
assert_eq!(processor.registers.stack_pointer, test_case.r#final.sp, "stack pointer was incorrect");
for (addr, value) in test_case.r#final.ram {
let stored_val = processor