def testShouldRotateFaceBeingRotatedCounterClockwise(self): cube = Cube() face = ['0', '1', '2', '3', '4', '5', '6', '7', '8'] expectedRotatedFace = ['2', '5', '8', '1', '4', '7', '0', '3', '6'] actualRotatedFace = cube._rotateCallingFace(face, COUNTER_CLOCKWISE) self.assertEquals(actualRotatedFace, expectedRotatedFace)
def testShouldRotatePartOfFaceBeingRotatedClockwise(self): cube = Cube() face = ['0', 'g', 'g', 'g', 'g', 'g', 'g', 'g', 'g'] newFace = cube._rotateCallingFace(face, CLOCKWISE) self.assertEquals(newFace[2], face[0])