diff options
author | Hiroshi SHIBATA <[email protected]> | 2020-01-12 08:14:26 +0900 |
---|---|---|
committer | SHIBATA Hiroshi <[email protected]> | 2020-01-12 12:28:29 +0900 |
commit | e61cab3a367c4040a2a487dd893c7be9a37889a9 (patch) | |
tree | c6ea3e3c929fcb5fd17197abea387173912f624b /spec/ruby/library/rexml/document/xml_decl_spec.rb | |
parent | 83240f315a10b42b53c3b62c1fbc428f97912665 (diff) |
Ignore rexml examples on ruby/spec
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/2832
Diffstat (limited to 'spec/ruby/library/rexml/document/xml_decl_spec.rb')
-rw-r--r-- | spec/ruby/library/rexml/document/xml_decl_spec.rb | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/spec/ruby/library/rexml/document/xml_decl_spec.rb b/spec/ruby/library/rexml/document/xml_decl_spec.rb index 30288a150b..6862c7bb6b 100644 --- a/spec/ruby/library/rexml/document/xml_decl_spec.rb +++ b/spec/ruby/library/rexml/document/xml_decl_spec.rb @@ -1,15 +1,18 @@ -require 'rexml/document' require_relative '../../../spec_helper' -describe "REXML::Document#xml_decl" do - it "returns XML declaration of the document" do - d = REXML::Document.new - decl = REXML::XMLDecl.new("1.0", "UTF-16", "yes") - d.add decl - d.xml_decl.should == decl - end +ruby_version_is ''...'2.8' do + require 'rexml/document' + + describe "REXML::Document#xml_decl" do + it "returns XML declaration of the document" do + d = REXML::Document.new + decl = REXML::XMLDecl.new("1.0", "UTF-16", "yes") + d.add decl + d.xml_decl.should == decl + end - it "returns default XML declaration unless present" do - REXML::Document.new.xml_decl.should == REXML::XMLDecl.new + it "returns default XML declaration unless present" do + REXML::Document.new.xml_decl.should == REXML::XMLDecl.new + end end end |