Skip to content

Commit d47635f

Browse files
committed
more floor checks
1 parent cdee829 commit d47635f

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

tests/src/floor.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ fn test_floor() {
4343
emu.memory.iram_raw[labels::get("autorepeatY") as usize] = 0;
4444
emu.memory.iram_raw[labels::get("vramRow") as usize] = 0;
4545

46-
playfield::set_str(&mut emu,r##"
46+
playfield::set_str(&mut emu, r##"
4747
##### ####
4848
##### ####
4949
##### ####
@@ -57,6 +57,11 @@ fn test_floor() {
5757
for i in 0..40 {
5858
assert_eq!(emu.memory.iram_raw[i + labels::get("playfield") as usize], 0xEF);
5959
}
60+
61+
// check the floor is there
62+
assert_ne!(playfield::get(&mut emu, 0, 19), 0xEF);
63+
// but the row above isn't
64+
assert_eq!(playfield::get(&mut emu, 0, 18), 0xEF);
6065
}
6166

6267
fn test_floor0() {
@@ -93,7 +98,7 @@ fn test_floor0() {
9398
emu.memory.iram_raw[labels::get("autorepeatY") as usize] = 0;
9499
emu.memory.iram_raw[labels::get("vramRow") as usize] = 0;
95100

96-
playfield::set_str(&mut emu,r##"
101+
playfield::set_str(&mut emu, r##"
97102
##### ####
98103
##### ####
99104
##### ####

0 commit comments

Comments
 (0)