mirror of
https://github.com/kiwix/libkiwix.git
synced 2025-06-26 10:11:30 +00:00
[TEST] Do not try to use the bookId if it is wrong.
This commit is contained in:
@ -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);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user