Exemplo n.º 1
0
        public void ApplyRotateActionTest()
        {
            List <Vector2> coordinates;
            GameShape      shape = BasicShapeInitialize(out coordinates, defaultOri);

            shape.ApplyAction(InputAction.Rotate);

            //ensure rotation function called
            foreach (Block b in shape.blocks)
            {
                Assert.IsTrue(coordinates.Contains(b.GetPosition()));
            }
            //ensure orientation adjusted
            Assert.AreEqual(ShapeRenderer.Orientation.ORIENT_1, shape.GetOrientation());
        }