void RobotService_Left_Placed_Allowed(Facing start, Facing expected, [Frozen]Mock<IRobot> mockRobot, RobotService sut) { mockRobot.SetupProperty(x => x.Placed, true); mockRobot.SetupProperty(x => x.F, start); sut.Left(); mockRobot.VerifySet(r => r.F = expected, Times.Once()); }
void RobotService_Left_NotPlaced_Ignored(Facing start, Facing expected, [Frozen]Mock<IRobot> mockRobot, RobotService sut) { mockRobot.SetupProperty(x => x.Placed, false); mockRobot.SetupProperty(x => x.F, start); sut.Left(); mockRobot.VerifySet(r => r.F = expected, Times.Never()); }