summaryrefslogtreecommitdiff
path: root/spec/index_spec.rb
diff options
context:
space:
mode:
authorDan Allen <dan.j.allen@gmail.com>2019-06-01 00:21:59 -0600
committerDan Allen <dan.j.allen@gmail.com>2019-06-01 00:21:59 -0600
commit57519bbc570d4a95a8c798c42c9b0d19a693fda2 (patch)
tree99e038a7c03a19e0a1bd8b860b7b9abfa0d502a2 /spec/index_spec.rb
parentf4d6a97d0dd7181cf9333c458dc14d54bcc5e02a (diff)
add test to verify anchors for index terms are reproducible
Diffstat (limited to 'spec/index_spec.rb')
-rw-r--r--spec/index_spec.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/index_spec.rb b/spec/index_spec.rb
index 6768258f..7b4160f6 100644
--- a/spec/index_spec.rb
+++ b/spec/index_spec.rb
@@ -77,9 +77,10 @@ describe 'Asciidoctor::PDF::Converter - Index' do
(expect index_text.size).to eql 1
end
- it 'should use anchor names which are reproducible between runs' do
+ it 'should generate anchor names for indexterms which are reproducible between runs' do
input = <<~'EOS'
= Cats & Dogs
+ :reproducible:
== Cats
@@ -96,7 +97,7 @@ describe 'Asciidoctor::PDF::Converter - Index' do
to_file_a = to_pdf_file input, 'index-reproducible-a.pdf', doctype: :book
to_file_b = to_pdf_file input, 'index-reproducible-b.pdf', doctype: :book
- (expect FileUtils.compare_file to_file_a, to_file_a).to be true
+ (expect FileUtils.compare_file to_file_a, to_file_b).to be true
end
it 'should not automatically promote nested index terms' do