コード例 #1
0
        public void AddToMenu_ShouldGetCorrectBoolean()
        {
            MenuDetails           content    = new MenuDetails();
            MenuDetailsRepository repository = new MenuDetailsRepository();
            bool addResult = repository.AddMenuDetails(content);

            Assert.IsTrue(addResult);
            Console.WriteLine(addResult);
        }
コード例 #2
0
        public void GetMenu_ShouldReturnCorrectCollection()
        {
            MenuDetails           content = new MenuDetails();
            MenuDetailsRepository repo    = new MenuDetailsRepository();

            repo.AddMenuDetails(content);
            List <MenuDetails> menuList = repo.GetDetails();
            bool menuHasContent         = menuList.Contains(content);

            Assert.IsTrue(menuHasContent);
        }