summaryrefslogtreecommitdiff
path: root/test/rss/test_xml-stylesheet.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/rss/test_xml-stylesheet.rb')
-rw-r--r--test/rss/test_xml-stylesheet.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/rss/test_xml-stylesheet.rb b/test/rss/test_xml-stylesheet.rb
index cc19a38287e..6edafaeaa05 100644
--- a/test/rss/test_xml-stylesheet.rb
+++ b/test/rss/test_xml-stylesheet.rb
@@ -94,9 +94,9 @@ module RSS
end
def parse_pi(pi)
- /\A\s*<\?(\S+)([^(?:\?>)]+)\?>\s*\z/ =~ pi
+ /\A\s*<\?(\S+)([^?]*\?+(?:[^?>][^?]*\?+)*)>\s*\z/ =~ pi
target = $1
- dummy = REXML::Document.new("<dummy #{$2}/>").root
+ dummy = REXML::Document.new("<dummy #{$2.to_s.chop}/>").root
contents = {}
dummy.attributes.each do |name, value|
contents[name] = value