diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2014-06-19 01:28:02 -0600 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2014-06-19 01:28:02 -0600 |
| commit | 3c8d2d1f02f9836353e3cd27fa0ee398bcf06030 (patch) | |
| tree | 57df293bad9e0f2d572f516c9d7db39c420dd60f /test | |
| parent | acb1092b439a495f0d37339272c4031d8da297bd (diff) | |
resolves #929 only include xmlns in docbook45 backend if xmlns attribute is specified
Diffstat (limited to 'test')
| -rw-r--r-- | test/document_test.rb | 4 | ||||
| -rw-r--r-- | test/invoker_test.rb | 2 | ||||
| -rw-r--r-- | test/text_test.rb | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/test/document_test.rb b/test/document_test.rb index ecb8b361..efdbade5 100644 --- a/test/document_test.rb +++ b/test/document_test.rb @@ -1331,7 +1331,7 @@ section body end test 'docbook45 backend doctype article no xmlns' do - result = render_string('text', :keep_namespaces => true, :attributes => {'backend' => 'docbook45', 'doctype' => 'article', 'noxmlns' => ''}) + result = render_string('text', :keep_namespaces => true, :attributes => {'backend' => 'docbook45', 'doctype' => 'article'}) refute_match(RE_XMLNS_ATTRIBUTE, result) end @@ -1363,7 +1363,7 @@ chapter body end test 'docbook45 backend doctype book no xmlns' do - result = render_string('text', :keep_namespaces => true, :attributes => {'backend' => 'docbook45', 'doctype' => 'book', 'noxmlns' => ''}) + result = render_string('text', :keep_namespaces => true, :attributes => {'backend' => 'docbook45', 'doctype' => 'book'}) refute_match(RE_XMLNS_ATTRIBUTE, result) end diff --git a/test/invoker_test.rb b/test/invoker_test.rb index 5a408a98..1b9b7265 100644 --- a/test/invoker_test.rb +++ b/test/invoker_test.rb @@ -357,7 +357,7 @@ context 'Invoker' do end test 'should set backend to docbook45 if specified' do - invoker = invoke_cli_to_buffer %w(-b docbook45 -o -) + invoker = invoke_cli_to_buffer %w(-b docbook45 -a xmlns -o -) doc = invoker.document assert_equal 'docbook45', doc.attr('backend') assert_equal '.xml', doc.attr('outfilesuffix') diff --git a/test/text_test.rb b/test/text_test.rb index 8b595673..7ed02564 100644 --- a/test/text_test.rb +++ b/test/text_test.rb @@ -18,7 +18,7 @@ context "Text" do end test "proper encoding to handle utf8 characters in document using docbook45 backend" do - output = example_document(:encoding, :attributes => {'backend' => 'docbook45'}).render + output = example_document(:encoding, :attributes => {'backend' => 'docbook45', 'xmlns' => ''}).render assert_xpath '//xmlns:simpara', output, 4 assert_xpath '//xmlns:ulink', output, 1 end |
