Example #1
0
 public void OnEnable()
 {
     destinations = transform.Find("Destinations").gameObject;
     menhirs      = transform.Find("Menhirs").gameObject;
     scoreBoard   = transform.GetComponentInChildren <TextMeshPro>();
     obelix       = transform.GetComponentInChildren <Obelix>();
 }
Example #2
0
        public void TestMethod(int x, int y, int result)
        {
            var obelix = new Obelix();
            var r      = obelix.Mul(x, y);

            Assert.That(r, Is.EqualTo(result));
        }
Example #3
0
        public void MultipleCalculations()
        {
            var obelix = new Obelix();

            for (int i = 1; i < 999; i++)
            {
                for (int j = 1; j < 999; j++)
                {
                    Assert.That(() => obelix.Mul(i, j), Is.EqualTo(i * j));
                }
            }
        }
Example #4
0
        public void InvadlidNumber(int x, int y)
        {
            var obelix = new Obelix();

            Assert.That(() => obelix.Mul(x, y), Throws.ArgumentException);
        }