예제 #1
0
        public void CanGetAuthorsforbook(int bookid, int expected)
        {
            BookRepoAdo   repo    = new BookRepoAdo();
            List <Author> authors = repo.GetAuthorsByBook(bookid);

            Assert.AreEqual(expected, authors.Count);
        }
예제 #2
0
        public void CanGetBooksByAuthor(int AuthorID, int expected)
        {
            BookRepoAdo repo  = new BookRepoAdo();
            List <Book> books = repo.GetBooksByAuthor(AuthorID);

            Assert.AreEqual(expected, books.Count);
        }
예제 #3
0
        public void CanGetAllBooks()
        {
            BookRepoAdo repo  = new BookRepoAdo();
            List <Book> Books = repo.LoadAllBooks();

            Assert.IsNotEmpty(Books);
        }