Test [pagebreak] 🗞
This commit is contained in:
parent
81e80ecfba
commit
0adbfe894a
@ -1,7 +1,10 @@
|
||||
# Tests
|
||||
|
||||
- `typ`: Input files
|
||||
- `ref`: Reference images which the output is compared with to determine
|
||||
whether a test passed or failed
|
||||
- `res`: Resource files used by tests
|
||||
- `out`: PNG and PDF files produced by tests
|
||||
- `typ`: Input files.
|
||||
- `ref`: Reference images which the output is compared with to determine whether
|
||||
a test passed or failed. To keep things small, please run
|
||||
`oxipng -o max tests/ref/<img>` when creating or updating reference
|
||||
images (note that `<img>` can be `*` to optimize all images).
|
||||
- `res`: Resource files used by tests.
|
||||
- `out`: PNG and PDF files produced by tests.
|
||||
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 2.7 KiB |
BIN
tests/ref/pagebreak.png
Normal file
BIN
tests/ref/pagebreak.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.0 KiB |
@ -1,11 +1,11 @@
|
||||
// Test error cases of the `image` function.
|
||||
|
||||
// compare-ref: false
|
||||
// error: 8:9-8:30 failed to load image
|
||||
// error: 11:9-11:30 failed to load image
|
||||
|
||||
// File does not exist.
|
||||
[image: "path/does/not/exist"]
|
||||
|
||||
// File exists, but is no image.
|
||||
[image: "typ/image-error.typ"]
|
||||
|
||||
// compare-ref: false
|
||||
// error: 4:9-4:30 failed to load image
|
||||
// error: 7:9-7:30 failed to load image
|
||||
|
@ -6,6 +6,6 @@
|
||||
[page][Second]
|
||||
[pagebreak]
|
||||
Fourth
|
||||
[page][Fifth]
|
||||
[page][]
|
||||
Sixth
|
||||
[page][Seventh and last]
|
||||
|
@ -1,11 +1,11 @@
|
||||
// Test error cases of the `page` function.
|
||||
|
||||
// compare-ref: false
|
||||
// error: 8:8-8:19 invalid paper
|
||||
// error: 11:17-11:20 aligned axis
|
||||
|
||||
// Invalid paper.
|
||||
[page: nonexistant]
|
||||
|
||||
// Aligned axes.
|
||||
[page: main-dir=ltr]
|
||||
|
||||
// compare-ref: false
|
||||
// error: 4:8-4:19 invalid paper
|
||||
// error: 7:17-7:20 aligned axis
|
||||
|
5
tests/typ/pagebreak.typ
Normal file
5
tests/typ/pagebreak.typ
Normal file
@ -0,0 +1,5 @@
|
||||
// Test trailing pagebreak.
|
||||
|
||||
First of two
|
||||
[pagebreak]
|
||||
[page: height=40pt]
|
Loading…
Reference in New Issue
Block a user