Ejemplo n.º 1
0
        public void BeDestroyedOnFullHealthDamage()
        {
            var tank = _factory.CreateLightTank();

            tank.TakeDamage(tank.HealthPoints);
            Assert.Equal(0u, tank.HealthPoints);
        }
Ejemplo n.º 2
0
        private static IEnumerable <Tank> GetTanks(TankFactory tankFactory)
        {
            yield return(tankFactory.CreateLightTank());

            yield return(tankFactory.CreateCompositeTank());

            yield return(tankFactory.CreateReactiveTank());
        }
Ejemplo n.º 3
0
 public void AddLightTank()
 {
     Add((T)_tankFactory.CreateLightTank());
     OnArmyChanged(new ArmyChangedEventArgs
     {
         Info = "Added light tank " + this.Last()
     });
 }