Esempio n. 1
0
        public void GetByActiveHaspKey()
        {
            List <HaspKey> GetByActive;
            var            GetByActiveExpected = new List <HaspKey>
            {
                CreateNew(1),
            };

            using (var db = new EntitesContext())
            {
                ClearTable.HaspKeys(db);
                ClearTable.KeyFeatures(db);

                haspKeyL = Get(db);

                db.HaspKeys.AddRange(CreateListEntities.HaspKeys());
                db.KeyFeatures.AddRange(CreateListEntities.KeyFeatures());
                db.SaveChanges();

                GetByActive = haspKeyL.GetByActive();
            }

            CollectionAssert.AreEqual(GetByActive, GetByActiveExpected);
        }
Esempio n. 2
0
 public List <ModelViewHaspKey> GetByActive()
 => Convert(keyLogic.GetByActive());