diff options
| author | Laurenz <laurmaedje@gmail.com> | 2024-12-02 13:37:33 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2024-12-04 10:12:07 +0100 |
| commit | f8f2ba6a5f8c8ca7dbb85cf17b73332a0c301c60 (patch) | |
| tree | b3bc754509fb3ab4c74493848fe96f116b7907ed /tests/src/custom.rs | |
| parent | 76c24ee6e35715cd14bb892d7b6b8d775c680bf7 (diff) | |
Rename `Document` to `PagedDocument`
Diffstat (limited to 'tests/src/custom.rs')
| -rw-r--r-- | tests/src/custom.rs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/src/custom.rs b/tests/src/custom.rs index 9a5fef03..965312ab 100644 --- a/tests/src/custom.rs +++ b/tests/src/custom.rs @@ -1,7 +1,8 @@ use std::fmt::Write; use typst::foundations::Smart; -use typst::model::{Document, DocumentInfo}; +use typst::layout::PagedDocument; +use typst::model::DocumentInfo; use typst::World; use crate::collect::Test; @@ -18,7 +19,7 @@ macro_rules! test_eq { /// Run special checks for specific tests for which it is not worth it to create /// custom annotations. -pub fn check(test: &Test, world: &TestWorld, doc: Option<&Document>) -> String { +pub fn check(test: &Test, world: &TestWorld, doc: Option<&PagedDocument>) -> String { let mut sink = String::new(); match test.name.as_str() { "document-set-author-date" => { @@ -41,6 +42,6 @@ pub fn check(test: &Test, world: &TestWorld, doc: Option<&Document>) -> String { } /// Extract the document information. -fn info(doc: Option<&Document>) -> DocumentInfo { +fn info(doc: Option<&PagedDocument>) -> DocumentInfo { doc.map(|doc| doc.info.clone()).unwrap_or_default() } |
