1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-01-12 15:31:09 +00:00

Adjusted slightly to adapt to latest Swift warnings.

This commit is contained in:
Thomas Harte 2017-05-17 07:49:48 -04:00
parent 1378ab7278
commit 64d6ee1be5
3 changed files with 6 additions and 5 deletions

View File

@ -7,7 +7,6 @@
// //
import XCTest import XCTest
@testable import Clock_Signal
class AllSuiteATests: XCTestCase { class AllSuiteATests: XCTestCase {

View File

@ -2,6 +2,8 @@
// Use this file to import your target's public headers that you would like to expose to Swift. // Use this file to import your target's public headers that you would like to expose to Swift.
// //
#import "ClockSignal-Bridging-Header.h"
#import "TestMachine6502.h" #import "TestMachine6502.h"
#import "TestMachineZ80.h" #import "TestMachineZ80.h"
#import "MOS6522Bridge.h" #import "MOS6522Bridge.h"

View File

@ -37,16 +37,16 @@ class KlausDormannTests: XCTestCase {
let machine = CSTestMachine6502() let machine = CSTestMachine6502()
machine.setData(functionalTest, atAddress: 0) machine.setData(functionalTest, atAddress: 0)
machine.setValue(0x400, for: CSTestMachine6502Register.programCounter) machine.setValue(0x400, for: .programCounter)
while true { while true {
let oldPC = machine.value(for: CSTestMachine6502Register.lastOperationAddress) let oldPC = machine.value(for: .lastOperationAddress)
machine.runForNumber(ofCycles: 1000) machine.runForNumber(ofCycles: 1000)
let newPC = machine.value(for: CSTestMachine6502Register.lastOperationAddress) let newPC = machine.value(for: .lastOperationAddress)
if newPC == oldPC { if newPC == oldPC {
let error = errorForTrapAddress(oldPC) let error = errorForTrapAddress(oldPC)
XCTAssert(error == nil, "Failed with error \(error)") XCTAssert(error == nil, "Failed with error \(error!)")
return return
} }
} }