public int GetSolidTonsGeneratedForAnimalSubType(int animalSubTypeId,
                                                         int animalCount,
                                                         int daysCollected)
        {
            var poundPerDay = _sd.GetAnimalSubType(animalSubTypeId).SolidPerPoundPerAnimalPerDay;

            var result = (animalCount * poundPerDay * daysCollected / 2000);

            return(Convert.ToInt32(result ?? 0));
        }
Exemple #2
0
        public void CompareGetAnimalSubType()
        {
            //Beef
            var actual   = _agriRepository.GetAnimalSubType(1);
            var expected = _staticExtRepo.GetAnimalSubType(1);

            Assert.IsNotNull(actual);
            Assert.IsNotNull(actual.Animal);
            Assert.AreEqual(expected.AnimalId, actual.AnimalId);
            Assert.AreEqual(expected.Name, actual.Name);
        }