From 17bc1a3e1a5e9cf1244bebdf79c6087f7e27512b Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Wed, 20 Jan 2021 16:37:22 +0100 Subject: [PATCH] [TEST] Do not try to use the bookId if it is wrong. --- test/manager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/manager.cpp b/test/manager.cpp index 6a2bbe8bd..13446c466 100644 --- a/test/manager.cpp +++ b/test/manager.cpp @@ -11,7 +11,7 @@ TEST(ManagerTest, addBookFromPathAndGetIdTest) kiwix::Manager manager = kiwix::Manager(&lib); auto bookId = manager.addBookFromPathAndGetId("./test/example.zim"); - EXPECT_NE(bookId, ""); + ASSERT_NE(bookId, ""); kiwix::Book book = lib.getBookById(bookId); EXPECT_EQ(book.getPath(), computeAbsolutePath("", "./test/example.zim")); @@ -22,4 +22,4 @@ TEST(ManagerTest, addBookFromPathAndGetIdTest) auto savedPath = computeAbsolutePath(removeLastPathElement(manager.writableLibraryPath), pathToSave); EXPECT_EQ(book.getPath(), savedPath); EXPECT_EQ(book.getUrl(), url); -} \ No newline at end of file +}