diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2020-03-29 23:58:41 -0600 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2020-03-30 00:02:53 -0600 |
| commit | ea593d73bbcedbc10e28ee77b4a73996b118caf6 (patch) | |
| tree | b9ce2a1c3bf5c9f32563e7a8d611aeaf3cb5325f | |
| parent | 53fab4490054779c25d3f24244876a4f98a2f289 (diff) | |
test behavior of delimited block with trailing page break
| -rw-r--r-- | spec/reference/sidebar-with-trailing-page-break.pdf | bin | 0 -> 19179 bytes | |||
| -rw-r--r-- | spec/sidebar_spec.rb | 17 |
2 files changed, 17 insertions, 0 deletions
diff --git a/spec/reference/sidebar-with-trailing-page-break.pdf b/spec/reference/sidebar-with-trailing-page-break.pdf Binary files differnew file mode 100644 index 00000000..eb99d926 --- /dev/null +++ b/spec/reference/sidebar-with-trailing-page-break.pdf diff --git a/spec/sidebar_spec.rb b/spec/sidebar_spec.rb index 3b9633cd..337f0fcb 100644 --- a/spec/sidebar_spec.rb +++ b/spec/sidebar_spec.rb @@ -89,6 +89,23 @@ describe 'Asciidoctor::PDF::Converter - Sidebar' do (expect to_file).to visually_match 'sidebar-page-split.pdf' end + it 'should extend block to bottom of page but not beyond if content ends with page break', visual: true do + to_file = to_pdf_file <<~'EOS', 'sidebar-with-trailing-page-break.pdf' + .Sidebar Title + **** + Sidebar + + Contents + + <<< + **** + + after + EOS + + (expect to_file).to visually_match 'sidebar-with-trailing-page-break.pdf' + end + it 'should not add border if border width is not set in theme or value is nil' do pdf = to_pdf <<~'EOS', pdf_theme: { sidebar_border_color: 'AA0000', sidebar_border_width: nil }, analyze: :line **** |
