コード例 #1
0
        public void MoveUpRight()
        {
            GameObject obj = new GameObject();
            obj.MoveUp();
            obj.MoveRight();

            Vector2 expected = -Vector2.UnitY + Vector2.UnitX;
            //expected.Normalize();
            Assert.That(obj.Velocity, Is.EqualTo(expected));
        }
コード例 #2
0
 public void MoveUp()
 {
     GameObject obj = new GameObject();
     obj.MoveUp();
     Assert.That(obj.Velocity, Is.EqualTo(-Vector2.UnitY));
 }