mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-29 06:02:07 +03:00
Tests/LibPDF: Use MUST() more
No behavior change.
This commit is contained in:
parent
5998072f15
commit
e0887dd045
Notes:
sideshowbarker
2024-07-17 03:25:24 +09:00
Author: https://github.com/nico Commit: https://github.com/SerenityOS/serenity/commit/e0887dd045 Pull-request: https://github.com/SerenityOS/serenity/pull/19947 Reviewed-by: https://github.com/mattco98 ✅
@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
TEST_CASE(linearized_pdf)
|
TEST_CASE(linearized_pdf)
|
||||||
{
|
{
|
||||||
auto file = Core::MappedFile::map("linearized.pdf"sv).release_value();
|
auto file = MUST(Core::MappedFile::map("linearized.pdf"sv));
|
||||||
auto document = MUST(PDF::Document::create(file->bytes()));
|
auto document = MUST(PDF::Document::create(file->bytes()));
|
||||||
MUST(document->initialize());
|
MUST(document->initialize());
|
||||||
EXPECT_EQ(document->get_page_count(), 1U);
|
EXPECT_EQ(document->get_page_count(), 1U);
|
||||||
@ -21,7 +21,7 @@ TEST_CASE(linearized_pdf)
|
|||||||
|
|
||||||
TEST_CASE(non_linearized_pdf)
|
TEST_CASE(non_linearized_pdf)
|
||||||
{
|
{
|
||||||
auto file = Core::MappedFile::map("non-linearized.pdf"sv).release_value();
|
auto file = MUST(Core::MappedFile::map("non-linearized.pdf"sv));
|
||||||
auto document = MUST(PDF::Document::create(file->bytes()));
|
auto document = MUST(PDF::Document::create(file->bytes()));
|
||||||
MUST(document->initialize());
|
MUST(document->initialize());
|
||||||
EXPECT_EQ(document->get_page_count(), 1U);
|
EXPECT_EQ(document->get_page_count(), 1U);
|
||||||
@ -29,7 +29,7 @@ TEST_CASE(non_linearized_pdf)
|
|||||||
|
|
||||||
TEST_CASE(complex_pdf)
|
TEST_CASE(complex_pdf)
|
||||||
{
|
{
|
||||||
auto file = Core::MappedFile::map("complex.pdf"sv).release_value();
|
auto file = MUST(Core::MappedFile::map("complex.pdf"sv));
|
||||||
auto document = MUST(PDF::Document::create(file->bytes()));
|
auto document = MUST(PDF::Document::create(file->bytes()));
|
||||||
MUST(document->initialize());
|
MUST(document->initialize());
|
||||||
EXPECT_EQ(document->get_page_count(), 3U);
|
EXPECT_EQ(document->get_page_count(), 3U);
|
||||||
|
Loading…
Reference in New Issue
Block a user