From 6d31e06e59b30ea463af77317001d246a6a96652 Mon Sep 17 00:00:00 2001 From: BigEd Date: Thu, 25 Nov 2010 06:36:49 +0800 Subject: [PATCH] fixup probable typos in 65c02 test suite flag preparation --- src/py65/tests/devices/test_mpu65c02.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/py65/tests/devices/test_mpu65c02.py b/src/py65/tests/devices/test_mpu65c02.py index 905ef00..14426a5 100644 --- a/src/py65/tests/devices/test_mpu65c02.py +++ b/src/py65/tests/devices/test_mpu65c02.py @@ -175,7 +175,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_abs_x_copies_bit_7_of_memory_to_n_flag_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.NEGATIVE + mpu.p |= mpu.NEGATIVE mpu.x = 0x02 self._write(mpu.memory, 0x0000, (0x3C, 0xEB, 0xFE)) #=> BIT $FEEB,X mpu.memory[0xFEED] = 0x00 @@ -199,7 +199,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_abs_x_copies_bit_6_of_memory_to_v_flag_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.OVERFLOW + mpu.p |= mpu.OVERFLOW mpu.x = 0x02 self._write(mpu.memory, 0x0000, (0x3C, 0xEB, 0xFE)) #=> BIT $FEEB,X mpu.memory[0xFEED] = 0x00 @@ -211,7 +211,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_abs_x_stores_result_of_and_in_z_while_preserving_a_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.ZERO + mpu.p &= ~mpu.ZERO mpu.x = 0x02 self._write(mpu.memory, 0x0000, (0x3C, 0xEB, 0xFE)) #=> BIT $FEEB,X mpu.memory[0xFEED] = 0x00 @@ -225,7 +225,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_abs_x_stores_result_of_and_when_nonzero_in_z_while_preserving_a(self): mpu = self._make_mpu() - mpu.p &= mpu.ZERO + mpu.p |= mpu.ZERO mpu.x = 0x02 self._write(mpu.memory, 0x0000, (0x3C, 0xEB, 0xFE)) #=> BIT $FEEB,X mpu.memory[0xFEED] = 0x01 @@ -267,7 +267,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_zp_x_copies_bit_7_of_memory_to_n_flag_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.NEGATIVE + mpu.p |= mpu.NEGATIVE self._write(mpu.memory, 0x0000, (0x34, 0x10)) #=> BIT $0010,X mpu.memory[0x0013] = 0x00 mpu.x = 0x03 @@ -291,7 +291,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_zp_x_copies_bit_6_of_memory_to_v_flag_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.OVERFLOW + mpu.p |= mpu.OVERFLOW self._write(mpu.memory, 0x0000, (0x34, 0x10)) #=> BIT $0010,X mpu.memory[0x0013] = 0x00 mpu.x = 0x03 @@ -303,7 +303,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_zp_x_stores_result_of_and_in_z_while_preserving_a_when_1(self): mpu = self._make_mpu() - mpu.p &= mpu.ZERO + mpu.p &= ~mpu.ZERO self._write(mpu.memory, 0x0000, (0x34, 0x10)) #=> BIT $0010,X mpu.memory[0x0013] = 0x00 mpu.x = 0x03 @@ -317,7 +317,7 @@ class MPUTests(unittest.TestCase, Common6502Tests): def test_bit_zp_x_stores_result_of_and_when_nonzero_in_z_while_preserving_a(self): mpu = self._make_mpu() - mpu.p &= mpu.ZERO + mpu.p |= mpu.ZERO self._write(mpu.memory, 0x0000, (0x34, 0x10)) #=> BIT $0010,X mpu.memory[0x0013] = 0x01 mpu.x = 0x03