diff options
author | Hiroshi SHIBATA <[email protected]> | 2025-05-08 19:41:20 +0900 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2025-05-09 14:27:28 +0900 |
commit | ce6c1778fb90f9685f9e790f111184d622f981be (patch) | |
tree | ea453918436bf8252385481bc769c775d30842a6 /spec/ruby/library/cgi/unescapeHTML_spec.rb | |
parent | 600c616507b258cdf9dbfbc822deb267f3202325 (diff) |
Guard CGI examples with Ruby 3.5 and use cgi/escape for related examples
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/13275
Diffstat (limited to 'spec/ruby/library/cgi/unescapeHTML_spec.rb')
-rw-r--r-- | spec/ruby/library/cgi/unescapeHTML_spec.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/ruby/library/cgi/unescapeHTML_spec.rb b/spec/ruby/library/cgi/unescapeHTML_spec.rb index 84b30c6aa6..e43dcc83e5 100644 --- a/spec/ruby/library/cgi/unescapeHTML_spec.rb +++ b/spec/ruby/library/cgi/unescapeHTML_spec.rb @@ -1,5 +1,9 @@ require_relative '../../spec_helper' -require 'cgi' +begin + require 'cgi/escape' +rescue LoadError + require 'cgi' +end describe "CGI.unescapeHTML" do it "unescapes '& < > "' to '& < > \"'" do |