We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 60b8b85 commit 67ad71eCopy full SHA for 67ad71e
test/html/pipeline/toc_filter_test.rb
@@ -1,3 +1,4 @@
1
+# encoding: utf-8
2
require "test_helper"
3
4
class HTML::Pipeline::TableOfContentsFilterTest < Test::Unit::TestCase
@@ -42,6 +43,13 @@ def test_all_header_tags_are_found_when_adding_anchors
42
43
doc = TocFilter.call(orig)
44
assert_equal 6, doc.search('a').size
45
end
-end
46
47
+ def test_anchors_with_non_english_stuff
48
+ orig = %(<h1>日本語</h1>
49
+ <h1>Русский</h1)
50
51
+ names = TocFilter.call(orig).search('a').map { |a| a['name'] }
52
+ assert_includes "日本語", names
53
+ assert_includes "Русский", names
54
+ end
55
+end
0 commit comments