Exemple #1
0
        public void TestAdd()
        {
            Category category = new Category()
            {
                Id    = 1,
                Name  = "Playa",
                Spots = null
            };
            var repository = new CategoryRepository(_context);

            repository.AddAndSave(category);

            Assert.AreEqual(_context.Find <Category>(category.Id), category);
        }