From 61be0afca83b19386f9d4a5c82ae176f28f65249 Mon Sep 17 00:00:00 2001 From: R Veera Kumar Date: Sun, 21 Nov 2021 16:52:28 +0530 Subject: [PATCH] Add expected state to all of case_addze in alu_cases unit test --- src/openpower/test/alu/alu_cases.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/src/openpower/test/alu/alu_cases.py b/src/openpower/test/alu/alu_cases.py index e03ee7a7..e743f749 100644 --- a/src/openpower/test/alu/alu_cases.py +++ b/src/openpower/test/alu/alu_cases.py @@ -159,13 +159,12 @@ class ALUTestCase(TestAccumulatorBase): lst = [f"{choice} 6, 16"] initial_regs = [0] * 32 initial_regs[16] = 0x00ff00ff00ff0080 - if choice == "addze": - e = ExpectedState(pc=4) - e.intregs[6] = 0xff00ff00ff0080 - e.intregs[16] = 0xff00ff00ff0080 - self.add_case(Program(lst, bigendian), initial_regs, expected=e) - else: - self.add_case(Program(lst, bigendian), initial_regs) + e = ExpectedState(pc=4) + e.intregs[16] = 0xff00ff00ff0080 + e.intregs[6] = 0xff00ff00ff0080 + if '.' in choice: + e.crregs[0] = 0x4 + self.add_case(Program(lst, bigendian), initial_regs, expected=e) def case_addis_nonzero_r0_regression(self): lst = [f"addis 3, 0, 1"] -- 2.30.2