예제 #1
0
        public void WeaponsSelect()
        {
            WeaponRepository repo = new WeaponRepository(new WeaponSQLContext());
            List <Weapon>    c    = repo.GetAll();

            Assert.IsNotNull(c, "Weapons weren't correctly retrieved");
        }
예제 #2
0
        public ActionResult Weapons()
        {
            weaponRepository = new WeaponRepository();
            var weapons = weaponRepository.GetAll();

            return(View(weapons));
        }
예제 #3
0
        public PagedResult <WeaponResource> GetWeapons(Query query, WeaponFilter filter)
        {
            var weaponsEnumerable = _weaponRepository.GetAll(query, filter);

            var result = _mapper.Map <PagedResult <WeaponResource> >(weaponsEnumerable);

            return(result);
        }
예제 #4
0
        public void ClearDatabase()
        {
            List <Weapon>   weapons   = mediatorweapon.GetAll();
            List <Warframe> warframes = mediatorwarframe.GetAll();

            for (int i = 1; i <= weapons.Capacity; i++)
            {
                mediatorweapon.DeleteByID(weapons[i].ID);
            }

            for (int i = 1; i <= warframes.Capacity; i++)
            {
                mediatorwarframe.DeleteByID(warframes[i].ID);
            }
        }
예제 #5
0
 public ActionResult Weapons()
 {
     return(View(weapon.GetAll()));
 }