Exemple #1
0
 def test_when_zero_result_sub_2comp(self):
     self.flags.set_from_add_result(emu8086.sub_2compl(1, 1, False), False)
     self.assertEquals(self.flags.cf(), 1)
Exemple #2
0
 def test_subtract_2compl(self):
     self.assertEqual(emu8086.sub_2compl(0, 1, True), 0xffff)
Exemple #3
0
 def test_sub_2compl_overflows(self):
     self.assertEqual(emu8086.sub_2compl(1, 1, True), 0x10000)
Exemple #4
0
 def test_when_zero_result_sub_2comp(self):
     self.flags.set_from_add_result(emu8086.sub_2compl(1, 1, False), False)
     self.assertEquals(self.flags.cf(), 1)
Exemple #5
0
 def test_subtract_2compl(self):
     self.assertEqual(emu8086.sub_2compl(0, 1, True), 0xffff)
Exemple #6
0
 def test_sub_2compl_overflows(self):
     self.assertEqual(emu8086.sub_2compl(1, 1, True), 0x10000)