diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2018-04-22 19:28:29 -0600 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2018-04-22 23:40:30 -0600 |
| commit | 253570eefb3d79cdb1586f53f20081f53edf1fe5 (patch) | |
| tree | a4001352bda2f5cc8d335702d3e28d000ffe0a39 /test/sections_test.rb | |
| parent | aeaea1105eace81aa5d92f25efeadedccdadb5c0 (diff) | |
change default value of numbered argument in Section#initialize to false
Diffstat (limited to 'test/sections_test.rb')
| -rw-r--r-- | test/sections_test.rb | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/test/sections_test.rb b/test/sections_test.rb index dfdea842..13d55f85 100644 --- a/test/sections_test.rb +++ b/test/sections_test.rb @@ -1228,49 +1228,49 @@ content context 'Section Numbering' do test 'should create section number with one entry for level 1' do doc = empty_document - sect1 = Asciidoctor::Section.new + sect1 = Asciidoctor::Section.new nil, nil, true doc << sect1 assert_equal '1.', sect1.sectnum end test 'should create section number with two entries for level 2' do doc = empty_document - sect1 = Asciidoctor::Section.new + sect1 = Asciidoctor::Section.new nil, nil, true doc << sect1 - sect1_1 = Asciidoctor::Section.new(sect1) + sect1_1 = Asciidoctor::Section.new sect1, nil, true sect1 << sect1_1 assert_equal '1.1.', sect1_1.sectnum end test 'should create section number with three entries for level 3' do doc = empty_document - sect1 = Asciidoctor::Section.new + sect1 = Asciidoctor::Section.new nil, nil, true doc << sect1 - sect1_1 = Asciidoctor::Section.new(sect1) + sect1_1 = Asciidoctor::Section.new sect1, nil, true sect1 << sect1_1 - sect1_1_1 = Asciidoctor::Section.new(sect1_1) + sect1_1_1 = Asciidoctor::Section.new sect1_1, nil, true sect1_1 << sect1_1_1 assert_equal '1.1.1.', sect1_1_1.sectnum end test 'should create section number for second section in level' do doc = empty_document - sect1 = Asciidoctor::Section.new + sect1 = Asciidoctor::Section.new nil, nil, true doc << sect1 - sect1_1 = Asciidoctor::Section.new(sect1) + sect1_1 = Asciidoctor::Section.new sect1, nil, true sect1 << sect1_1 - sect1_2 = Asciidoctor::Section.new(sect1) + sect1_2 = Asciidoctor::Section.new sect1, nil, true sect1 << sect1_2 assert_equal '1.2.', sect1_2.sectnum end test 'sectnum should use specified delimiter and append string' do doc = empty_document - sect1 = Asciidoctor::Section.new + sect1 = Asciidoctor::Section.new nil, nil, true doc << sect1 - sect1_1 = Asciidoctor::Section.new(sect1) + sect1_1 = Asciidoctor::Section.new sect1, nil, true sect1 << sect1_1 - sect1_1_1 = Asciidoctor::Section.new(sect1_1) + sect1_1_1 = Asciidoctor::Section.new sect1_1, nil, true sect1_1 << sect1_1_1 assert_equal '1,1,1,', sect1_1_1.sectnum(',') assert_equal '1:1:1', sect1_1_1.sectnum(':', false) @@ -1638,7 +1638,7 @@ content EOS doc = document_from_string input - second_section = Asciidoctor::Section.new doc + second_section = Asciidoctor::Section.new doc, nil, true doc.blocks.insert 1, second_section doc.reindex_sections sections = doc.sections |
