1
0
mirror of https://github.com/rkujawa/rk65c02.git synced 2024-12-11 18:49:16 +00:00

Add test for LDA with absolute addressing.

This commit is contained in:
Radosław Kujawa 2017-01-23 10:28:44 +01:00
parent 9e32c3e493
commit 3cbede06f8
3 changed files with 9 additions and 0 deletions

View File

@ -13,6 +13,7 @@ TESTROMS=test_emulation_and_imm.rom \
test_emulation_php.rom test_emulation_plp.rom \
test_emulation_nop.rom \
test_emulation_lda_imm.rom test_emulation_lda_zp.rom \
test_emulation_lda_abs.rom \
test_emulation_stz_zp.rom
all : $(TESTS) $(TESTROMS)

View File

@ -100,6 +100,11 @@ ATF_TC_BODY(emul_lda, tc)
ATF_REQUIRE(rom_start(&e, "test_emulation_lda_zp.rom"));
ATF_CHECK(e.regs.A == 0xAE);
/* LDA absolute */
bus_write_1(&b, 0x2F5A, 0xEA);
ATF_REQUIRE(rom_start(&e, "test_emulation_lda_abs.rom"));
ATF_CHECK(e.regs.A == 0xEA);
bus_finish(&b);
}

View File

@ -0,0 +1,3 @@
start: lda 0x2F5A
stp