diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2021-01-18 23:59:30 -0700 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2021-01-19 01:34:44 -0700 |
| commit | b31b03478c7e41b1cab07a6dbaad48b4c21384a0 (patch) | |
| tree | 1b77e023479c16e77311311479e6b83e1b44858a | |
| parent | 84dd5ccf8ad048e7277f1e7b8a100b6d2653184c (diff) | |
fix order of font kerning tests in section context
| -rw-r--r-- | spec/section_spec.rb | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/spec/section_spec.rb b/spec/section_spec.rb index ceda2bf7..a6d8a7f5 100644 --- a/spec/section_spec.rb +++ b/spec/section_spec.rb @@ -104,17 +104,6 @@ describe 'Asciidoctor::PDF::Converter - Section' do (expect with_kerning_position).to be < without_kerning_position end - it 'should add text formatting styles to styles defined in theme' do - pdf = to_pdf <<~'EOS', pdf_theme: { heading_font_style: 'bold' }, analyze: true - == Get Started _Quickly_ - EOS - - text = pdf.text - (expect text).to have_size 2 - (expect text[0][:font_name]).to eql 'NotoSerif-Bold' - (expect text[1][:font_name]).to eql 'NotoSerif-BoldItalic' - end - it 'should allow theme to set font kerning per heading level' do pdf_theme = { heading_text_transform: 'uppercase', @@ -133,6 +122,17 @@ describe 'Asciidoctor::PDF::Converter - Section' do (expect kerning_positions[0]).to be < kerning_positions[1] end + it 'should add text formatting styles to styles defined in theme' do + pdf = to_pdf <<~'EOS', pdf_theme: { heading_font_style: 'bold' }, analyze: true + == Get Started _Quickly_ + EOS + + text = pdf.text + (expect text).to have_size 2 + (expect text[0][:font_name]).to eql 'NotoSerif-Bold' + (expect text[1][:font_name]).to eql 'NotoSerif-BoldItalic' + end + it 'should add text formatting styles to styles defined in theme for specific level' do pdf = to_pdf <<~'EOS', pdf_theme: { heading_font_style: nil, heading_h2_font_style: 'bold' }, analyze: true == Get Started _Quickly_ |
