mirror of
https://github.com/TomHarte/CLK.git
synced 2025-01-12 15:31:09 +00:00
Added DJNZ test.
This commit is contained in:
parent
cb277b8d1e
commit
fadbfdf801
@ -956,4 +956,27 @@ class Z80MachineCycleTests: XCTestCase {
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DJNZ
|
||||||
|
func testDJNZ() {
|
||||||
|
test(
|
||||||
|
program: [
|
||||||
|
0x06, 0x02, // LD B, 2
|
||||||
|
0x10, 0xfe, // DJNZ -2
|
||||||
|
],
|
||||||
|
busCycles: [
|
||||||
|
MachineCycle(operation: .readOpcode, length: 4),
|
||||||
|
MachineCycle(operation: .read, length: 3),
|
||||||
|
|
||||||
|
MachineCycle(operation: .readOpcode, length: 5),
|
||||||
|
MachineCycle(operation: .read, length: 3),
|
||||||
|
MachineCycle(operation: .internalOperation, length: 5),
|
||||||
|
|
||||||
|
MachineCycle(operation: .readOpcode, length: 5),
|
||||||
|
MachineCycle(operation: .read, length: 3),
|
||||||
|
|
||||||
|
MachineCycle(operation: .readOpcode, length: 4),
|
||||||
|
]
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user