nokogiri 1.4.3.1 → 1.4.4

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of nokogiri might be problematic. Click here for more details.

Files changed (57) hide show
  1. data/CHANGELOG.ja.rdoc +26 -0
  2. data/CHANGELOG.rdoc +26 -0
  3. data/Manifest.txt +3 -0
  4. data/README.ja.rdoc +0 -4
  5. data/README.rdoc +0 -4
  6. data/Rakefile +1 -0
  7. data/bin/nokogiri +6 -1
  8. data/ext/nokogiri/depend +358 -32
  9. data/ext/nokogiri/extconf.rb +1 -3
  10. data/ext/nokogiri/nokogiri.c +2 -0
  11. data/ext/nokogiri/nokogiri.h +7 -0
  12. data/ext/nokogiri/xml_dtd.c +2 -2
  13. data/ext/nokogiri/xml_io.c +2 -2
  14. data/ext/nokogiri/xml_node.c +31 -6
  15. data/ext/nokogiri/xml_node_set.c +1 -1
  16. data/ext/nokogiri/xml_sax_parser.c +1 -1
  17. data/ext/nokogiri/xml_sax_parser_context.c +40 -0
  18. data/ext/nokogiri/xml_xpath_context.c +33 -2
  19. data/ext/nokogiri/xslt_stylesheet.c +116 -4
  20. data/lib/nokogiri/css/generated_tokenizer.rb +1 -2
  21. data/lib/nokogiri/css/xpath_visitor.rb +15 -7
  22. data/lib/nokogiri/decorators/slop.rb +5 -3
  23. data/lib/nokogiri/ffi/libxml.rb +9 -0
  24. data/lib/nokogiri/ffi/structs/xml_parser_context.rb +2 -1
  25. data/lib/nokogiri/ffi/structs/xml_parser_input.rb +19 -0
  26. data/lib/nokogiri/ffi/xml/dtd.rb +2 -2
  27. data/lib/nokogiri/ffi/xml/node.rb +9 -4
  28. data/lib/nokogiri/ffi/xml/sax/parser_context.rb +12 -0
  29. data/lib/nokogiri/ffi/xml/xpath_context.rb +5 -0
  30. data/lib/nokogiri/ffi/xslt/stylesheet.rb +21 -1
  31. data/lib/nokogiri/html/document.rb +3 -3
  32. data/lib/nokogiri/html/document_fragment.rb +19 -17
  33. data/lib/nokogiri/version.rb +1 -1
  34. data/lib/nokogiri/xml/document.rb +26 -1
  35. data/lib/nokogiri/xml/document_fragment.rb +2 -2
  36. data/lib/nokogiri/xml/dtd.rb +11 -0
  37. data/lib/nokogiri/xml/node.rb +156 -45
  38. data/lib/nokogiri/xml/node_set.rb +2 -2
  39. data/lib/nokogiri/xml/reader.rb +36 -0
  40. data/lib/nokogiri/xml/sax/document.rb +4 -2
  41. data/lib/nokogiri/xslt.rb +9 -5
  42. data/tasks/cross_compile.rb +24 -2
  43. data/test/css/test_parser.rb +29 -18
  44. data/test/decorators/test_slop.rb +16 -0
  45. data/test/html/test_document_fragment.rb +46 -3
  46. data/test/html/test_node.rb +9 -0
  47. data/test/xml/sax/test_parser.rb +11 -3
  48. data/test/xml/sax/test_parser_context.rb +50 -0
  49. data/test/xml/sax/test_push_parser.rb +18 -1
  50. data/test/xml/test_document_fragment.rb +14 -2
  51. data/test/xml/test_dtd.rb +15 -0
  52. data/test/xml/test_node.rb +31 -2
  53. data/test/xml/test_node_reparenting.rb +59 -31
  54. data/test/xml/test_node_set.rb +13 -0
  55. data/test/xml/test_xpath.rb +32 -0
  56. data/test/xslt/test_custom_functions.rb +94 -0
  57. metadata +84 -80
@@ -100,13 +100,13 @@ module Nokogiri
100
100
  def test_xml_fragment_with_leading_whitespace
101
101
  doc = " <div>b</div> "
102
102
  fragment = Nokogiri::XML::Document.new.fragment(doc)
103
- assert_equal "<div>b</div>", fragment.to_s
103
+ assert_equal " <div>b</div> ", fragment.to_s
104
104
  end
105
105
 
106
106
  def test_xml_fragment_with_leading_whitespace_and_newline
107
107
  doc = " \n<div>b</div> "
108
108
  fragment = Nokogiri::XML::Document.new.fragment(doc)
109
- assert_equal "<div>b</div>", fragment.to_s
109
+ assert_equal " \n<div>b</div> ", fragment.to_s
110
110
  end
111
111
 
112
112
  def test_fragment_children_search
@@ -175,6 +175,18 @@ module Nokogiri
175
175
  end
176
176
  assert fragment.children.respond_to?(:awesome!), fragment.children.class
177
177
  end
178
+
179
+ def test_for_libxml_in_context_fragment_parsing_bug_workaround
180
+ 10.times do
181
+ begin
182
+ fragment = Nokogiri::XML.fragment("<div></div>")
183
+ parent = fragment.children.first
184
+ child = parent.parse("<h1></h1>").first
185
+ parent.add_child child
186
+ end
187
+ GC.start
188
+ end
189
+ end
178
190
  end
179
191
  end
180
192
  end
@@ -25,11 +25,26 @@ module Nokogiri
25
25
  end
26
26
  end
27
27
 
28
+ def test_empty_attributes
29
+ dtd = Nokogiri::HTML("<html></html>").internal_subset
30
+ assert_equal Hash.new, dtd.attributes
31
+ end
32
+
28
33
  def test_attributes
29
34
  assert_equal ['width'], @dtd.attributes.keys
30
35
  assert_equal '0', @dtd.attributes['width'].default
31
36
  end
32
37
 
38
+ def test_keys
39
+ assert_equal ['width'], @dtd.keys
40
+ end
41
+
42
+ def test_each
43
+ hash = {}
44
+ @dtd.each { |key, value| hash[key] = value }
45
+ assert_equal @dtd.attributes, hash
46
+ end
47
+
33
48
  def test_namespace
34
49
  assert_raise NoMethodError do
35
50
  @dtd.namespace
@@ -82,18 +82,47 @@ module Nokogiri
82
82
  assert_equal 0, list.length
83
83
  end
84
84
 
85
+ def test_parse_config_option
86
+ node = @xml.root
87
+ options = nil
88
+ node.parse("<item></item>") do |config|
89
+ options = config
90
+ end
91
+ assert_equal Nokogiri::XML::ParseOptions::DEFAULT_XML, options.to_i
92
+ end
93
+
85
94
  # descriptive, not prescriptive.
86
95
  def test_parse_invalid_html_markup_results_in_empty_nodeset
87
96
  doc = Nokogiri::HTML("<html></html>")
88
97
  nodeset = doc.root.parse "<div><div>a</div><snippet>b</snippet></div>"
89
98
  assert_equal 1, doc.errors.length # "Tag snippet invalid"
99
+ assert_equal 1, nodeset.length
100
+ end
101
+
102
+ def test_node_context_parsing_of_malformed_html_fragment_with_recover_is_corrected
103
+ doc = HTML.parse "<html><body><div></div></body></html>"
104
+ context_node = doc.at_css "div"
105
+ nodeset = context_node.parse("<div </div>") do |options|
106
+ options.recover
107
+ end
108
+ assert_equal "<div></div>", nodeset.to_s
109
+ assert_equal 1, doc.errors.length
110
+ assert_equal 1, nodeset.length
111
+ end
112
+
113
+ def test_node_context_parsing_of_malformed_html_fragment_without_recover_is_not_corrected
114
+ doc = HTML.parse "<html><body><div></div></body></html>"
115
+ context_node = doc.at_css "div"
116
+ nodeset = context_node.parse("<div </div>") do |options|
117
+ options.strict
118
+ end
119
+ assert_equal 1, doc.errors.length
90
120
  assert_equal 0, nodeset.length
91
121
  end
92
122
 
93
123
  def test_parse_error_list
94
124
  error_count = @xml.errors.length
95
- list = @xml.root.parse('<hello>')
96
- assert_equal 0, list.length
125
+ @xml.root.parse('<hello>')
97
126
  assert(error_count < @xml.errors.length, "errors should have increased")
98
127
  end
99
128
 
@@ -50,21 +50,22 @@ module Nokogiri
50
50
  # end
51
51
 
52
52
  {
53
- :add_child => {:target => "/root/a1", :returns => :reparented, :children_tags => %w[text b1 b2]},
54
- :<< => {:target => "/root/a1", :returns => :reparented, :children_tags => %w[text b1 b2]},
53
+ :add_child => {:target => "/root/a1", :returns_self => false, :children_tags => %w[text b1 b2]},
54
+ :<< => {:target => "/root/a1", :returns_self => false, :children_tags => %w[text b1 b2]},
55
55
 
56
- :replace => {:target => "/root/a1/node()", :returns => :reparented, :children_tags => %w[b1 b2]},
57
- :swap => {:target => "/root/a1/node()", :returns => :self, :children_tags => %w[b1 b2]},
56
+ :replace => {:target => "/root/a1/node()", :returns_self => false, :children_tags => %w[b1 b2]},
57
+ :swap => {:target => "/root/a1/node()", :returns_self => true, :children_tags => %w[b1 b2]},
58
58
 
59
- :inner_html= => {:target => "/root/a1", :returns => :self, :children_tags => %w[b1 b2]},
59
+ :children= => {:target => "/root/a1", :returns_self => false, :children_tags => %w[b1 b2]},
60
+ :inner_html= => {:target => "/root/a1", :returns_self => true, :children_tags => %w[b1 b2]},
60
61
 
61
- :add_previous_sibling => {:target => "/root/a1/text()", :returns => :reparented, :children_tags => %w[b1 b2 text]},
62
- :previous= => {:target => "/root/a1/text()", :returns => :reparented, :children_tags => %w[b1 b2 text]},
63
- :before => {:target => "/root/a1/text()", :returns => :self, :children_tags => %w[b1 b2 text]},
62
+ :add_previous_sibling => {:target => "/root/a1/text()", :returns_self => false, :children_tags => %w[b1 b2 text]},
63
+ :previous= => {:target => "/root/a1/text()", :returns_self => false, :children_tags => %w[b1 b2 text]},
64
+ :before => {:target => "/root/a1/text()", :returns_self => true, :children_tags => %w[b1 b2 text]},
64
65
 
65
- :add_next_sibling => {:target => "/root/a1/text()", :returns => :reparented, :children_tags => %w[text b1 b2]},
66
- :next= => {:target => "/root/a1/text()", :returns => :reparented, :children_tags => %w[text b1 b2]},
67
- :after => {:target => "/root/a1/text()", :returns => :self, :children_tags => %w[text b1 b2]}
66
+ :add_next_sibling => {:target => "/root/a1/text()", :returns_self => false, :children_tags => %w[text b1 b2]},
67
+ :next= => {:target => "/root/a1/text()", :returns_self => false, :children_tags => %w[text b1 b2]},
68
+ :after => {:target => "/root/a1/text()", :returns_self => true, :children_tags => %w[text b1 b2]}
68
69
  }.each do |method, params|
69
70
 
70
71
  before do
@@ -95,11 +96,12 @@ module Nokogiri
95
96
  end
96
97
 
97
98
  it "returns the expected value" do
98
- if params[:returns] == :self
99
- sendee = @doc.at_xpath(params[:target])
100
- sendee.send(method, @other_node).must_equal sendee
99
+ sendee = @doc.at_xpath(params[:target])
100
+ result = sendee.send(method, @other_node)
101
+ if params[:returns_self]
102
+ result.must_equal sendee
101
103
  else
102
- @doc.at_xpath(params[:target]).send(method, @other_node).must_equal @other_node
104
+ result.must_equal @other_node
103
105
  end
104
106
  end
105
107
  end
@@ -110,6 +112,17 @@ module Nokogiri
110
112
  @doc.at_xpath(params[:target]).send(method, @fragment_string)
111
113
  @doc.xpath("/root/a1/node()").collect {|n| n.name}.must_equal params[:children_tags]
112
114
  end
115
+
116
+ it "returns the expected value" do
117
+ sendee = @doc.at_xpath(params[:target])
118
+ result = sendee.send(method, @fragment_string)
119
+ if params[:returns_self]
120
+ result.must_equal sendee
121
+ else
122
+ result.must_be_kind_of Nokogiri::XML::NodeSet
123
+ result.to_html.must_equal @fragment_string
124
+ end
125
+ end
113
126
  end
114
127
  describe "passed a fragment" do
115
128
  it "inserts the fragment roots in the proper position" do
@@ -153,18 +166,6 @@ module Nokogiri
153
166
  end
154
167
 
155
168
  describe "ad hoc node reparenting behavior" do
156
- before do
157
- @xml = Nokogiri::XML "<root><a1>First node</a1><a2>Second node</a2><a3>Third node</a3></root>"
158
- @html = Nokogiri::HTML(<<-eohtml)
159
- <html>
160
- <head></head>
161
- <body>
162
- <div class='baz'><a href="foo" class="bar">first</a></div>
163
- </body>
164
- </html>
165
- eohtml
166
- end
167
-
168
169
  describe "#add_child" do
169
170
  describe "given a new node with a namespace" do
170
171
  it "keeps the namespace" do
@@ -223,7 +224,34 @@ module Nokogiri
223
224
  end
224
225
  end
225
226
 
227
+ describe "#add_previous_sibling" do
228
+ it "should not merge text nodes during the operation" do
229
+ xml = Nokogiri::XML %Q(<root>text node</root>)
230
+ replacee = xml.root.children.first
231
+ replacee.add_previous_sibling "foo <p></p> bar"
232
+ assert_equal "foo <p></p> bartext node", xml.root.children.to_html
233
+ end
234
+ end
235
+
236
+ describe "#add_next_sibling" do
237
+ it "should not merge text nodes during the operation" do
238
+ xml = Nokogiri::XML %Q(<root>text node</root>)
239
+ replacee = xml.root.children.first
240
+ replacee.add_next_sibling "foo <p></p> bar"
241
+ assert_equal "text nodefoo <p></p> bar", xml.root.children.to_html
242
+ end
243
+ end
244
+
226
245
  describe "#replace" do
246
+ describe "a text node with a text node" do
247
+ it "should not merge text nodes during the operation" do
248
+ xml = Nokogiri::XML %Q(<root>text node</root>)
249
+ replacee = xml.root.children.first
250
+ replacee.replace "new text node"
251
+ assert_equal "new text node", xml.root.children.first.content
252
+ end
253
+ end
254
+
227
255
  describe "when a document has a default namespace" do
228
256
  before do
229
257
  @fruits = Nokogiri::XML(<<-eoxml)
@@ -260,10 +288,10 @@ module Nokogiri
260
288
  </root>
261
289
  EOHTML
262
290
 
263
- root = doc.at("root")
264
- a = root.at("a")
265
- b = a.at("b")
266
- c = a.at("c")
291
+ assert root = doc.at("root")
292
+ assert a = root.at("a")
293
+ assert b = a.at("b")
294
+ assert c = a.at("c")
267
295
  a.add_next_sibling(b.unlink)
268
296
  c.unlink
269
297
  end
@@ -431,6 +431,19 @@ module Nokogiri
431
431
  assert_equal 'employee', @xml.search("//wrapper").first.children[0].name
432
432
  end
433
433
 
434
+ def test_wrap_a_fragment
435
+ frag = Nokogiri::XML::DocumentFragment.parse <<-EOXML
436
+ <employees>
437
+ <employee>hello</employee>
438
+ <employee>goodbye</employee>
439
+ </employees>
440
+ EOXML
441
+ employees = frag.xpath ".//employee"
442
+ employees.wrap("<wrapper/>")
443
+ assert_equal 'wrapper', employees[0].parent.name
444
+ assert_equal 'employee', frag.at(".//wrapper").children.first.name
445
+ end
446
+
434
447
  def test_wrap_preserves_document_structure
435
448
  assert_equal "employeeId",
436
449
  @xml.at_xpath("//employee").children.detect{|j| ! j.text? }.name
@@ -61,6 +61,10 @@ module Nokogiri
61
61
  }.new
62
62
  end
63
63
 
64
+ def test_variable_binding
65
+ assert_equal 4, @xml.xpath('//address[@domestic=$value]', nil, :value => 'Yes').length
66
+ end
67
+
64
68
  def test_unknown_attribute
65
69
  assert_equal 0, @xml.xpath('//employee[@id="asdfasdf"]/@fooo').length
66
70
  assert_nil @xml.xpath('//employee[@id="asdfasdf"]/@fooo')[0]
@@ -200,6 +204,34 @@ module Nokogiri
200
204
  nokogiri = Nokogiri::HTML.parse(doc)
201
205
  assert nokogiri.xpath(xpath)
202
206
  end
207
+
208
+ def test_custom_xpath_handler_with_args_under_gc_pressure
209
+ # see http://github.com/tenderlove/nokogiri/issues/#issue/345
210
+ tool_inspector = Class.new do
211
+ def name_equals(nodeset, name, *args)
212
+ nodeset.all? do |node|
213
+ args.each { |thing| thing.inspect }
214
+ node["name"] == name
215
+ end
216
+ end
217
+ end.new
218
+
219
+ xml = <<-EOXML
220
+ <toolbox>
221
+ #{"<tool name='hammer'/><tool name='wrench'/>" * 10}
222
+ </toolbox>
223
+ EOXML
224
+ doc = Nokogiri::XML xml
225
+
226
+ # long list of long arguments, to apply GC pressure during
227
+ # ruby_funcall argument marshalling
228
+ xpath = ["//tool[name_equals(.,'hammer'"]
229
+ 1000.times { xpath << "'unused argument #{'x' * 1000}'" }
230
+ xpath << "'unused argument')]"
231
+ xpath = xpath.join(',')
232
+
233
+ assert_equal doc.xpath("//tool[@name='hammer']"), doc.xpath(xpath, tool_inspector)
234
+ end
203
235
  end
204
236
  end
205
237
  end
@@ -0,0 +1,94 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ require "helper"
4
+
5
+ module Nokogiri
6
+ module XSLT
7
+ class TestCustomFunctions < Nokogiri::TestCase
8
+ def setup
9
+ super
10
+ @xml = Nokogiri.XML(<<-EOXML)
11
+ <?xml version="1.0" encoding="UTF-8"?>
12
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN"
13
+ "http://www.w3.org/TR/MathML2/dtd/xhtml-math11-f.dtd">
14
+ <html xmlns="http://www.w3.org/1999/xhtml" lang="en">
15
+ <head>
16
+ <meta http-equiv="Content-type" content="application/xhtml+xml"/>
17
+ <title>Foo</title>
18
+ </head>
19
+ <body>
20
+ <h1>Foo</h1>
21
+ <p>Lorem ipsum.</p>
22
+ </body>
23
+ </html>
24
+ EOXML
25
+ end
26
+
27
+ def test_function
28
+ skip("xslt custom functions not implemented under FFI") if Nokogiri.ffi?
29
+ foo = Class.new do
30
+ def capitalize nodes
31
+ nodes.first.content.upcase
32
+ end
33
+ end
34
+
35
+ XSLT.register "http://e.org/functions", foo
36
+
37
+ xsl = Nokogiri.XSLT(<<-EOXSL)
38
+ <?xml version="1.0"?>
39
+ <xsl:stylesheet version="1.0"
40
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
41
+ xmlns:f="http://e.org/functions"
42
+ extension-element-prefixes="f">
43
+
44
+ <xsl:template match="text()">
45
+ <xsl:copy-of select="f:capitalize(.)"/>
46
+ </xsl:template>
47
+
48
+ <xsl:template match="@*|node()">
49
+ <xsl:copy>
50
+ <xsl:apply-templates select="@*|node()"/>
51
+ <xsl:apply-imports/>
52
+ </xsl:copy>
53
+ </xsl:template>
54
+
55
+ </xsl:stylesheet>
56
+ EOXSL
57
+ result = xsl.transform @xml
58
+ assert_equal 'FOO', result.css('title').first.text
59
+ end
60
+
61
+ def test_function_XSLT
62
+ skip("xslt custom functions not implemented under FFI") if Nokogiri.ffi?
63
+ foo = Class.new do
64
+ def america nodes
65
+ nodes.first.content.upcase
66
+ end
67
+ end
68
+
69
+ xsl = Nokogiri.XSLT(<<-EOXSL, "http://e.org/functions" => foo)
70
+ <?xml version="1.0"?>
71
+ <xsl:stylesheet version="1.0"
72
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
73
+ xmlns:f="http://e.org/functions"
74
+ extension-element-prefixes="f">
75
+
76
+ <xsl:template match="text()">
77
+ <xsl:copy-of select="f:america(.)"/>
78
+ </xsl:template>
79
+
80
+ <xsl:template match="@*|node()">
81
+ <xsl:copy>
82
+ <xsl:apply-templates select="@*|node()"/>
83
+ <xsl:apply-imports/>
84
+ </xsl:copy>
85
+ </xsl:template>
86
+
87
+ </xsl:stylesheet>
88
+ EOXSL
89
+ result = xsl.transform @xml
90
+ assert_equal 'FOO', result.css('title').first.text
91
+ end
92
+ end
93
+ end
94
+ end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nokogiri
3
3
  version: !ruby/object:Gem::Version
4
- hash: 113
4
+ hash: 15
5
5
  prerelease: false
6
6
  segments:
7
7
  - 1
8
8
  - 4
9
- - 3
10
- - 1
11
- version: 1.4.3.1
9
+ - 4
10
+ version: 1.4.4
12
11
  platform: ruby
13
12
  authors:
14
13
  - Aaron Patterson
@@ -17,7 +16,7 @@ autorequire:
17
16
  bindir: bin
18
17
  cert_chain: []
19
18
 
20
- date: 2010-07-29 00:00:00 -07:00
19
+ date: 2010-11-16 00:00:00 -05:00
21
20
  default_executable:
22
21
  dependencies:
23
22
  - !ruby/object:Gem::Dependency
@@ -102,12 +101,12 @@ dependencies:
102
101
  requirements:
103
102
  - - ">="
104
103
  - !ruby/object:Gem::Version
105
- hash: 23
104
+ hash: 19
106
105
  segments:
107
106
  - 2
108
107
  - 6
109
- - 0
110
- version: 2.6.0
108
+ - 2
109
+ version: 2.6.2
111
110
  type: :development
112
111
  version_requirements: *id006
113
112
  description: "Nokogiri (\xE9\x8B\xB8) is an HTML, XML, SAX, and Reader parser. Among Nokogiri's\n\
@@ -123,43 +122,43 @@ extensions:
123
122
  - ext/nokogiri/extconf.rb
124
123
  extra_rdoc_files:
125
124
  - Manifest.txt
126
- - CHANGELOG.ja.rdoc
127
125
  - CHANGELOG.rdoc
128
- - README.ja.rdoc
126
+ - CHANGELOG.ja.rdoc
129
127
  - README.rdoc
130
- - ext/nokogiri/html_document.c
128
+ - README.ja.rdoc
129
+ - ext/nokogiri/xml_io.c
130
+ - ext/nokogiri/xml_sax_parser.c
131
+ - ext/nokogiri/xml_xpath_context.c
131
132
  - ext/nokogiri/html_element_description.c
132
- - ext/nokogiri/html_entity_lookup.c
133
- - ext/nokogiri/html_sax_parser_context.c
134
- - ext/nokogiri/nokogiri.c
135
- - ext/nokogiri/xml_attr.c
133
+ - ext/nokogiri/xml_libxml2_hacks.c
134
+ - ext/nokogiri/xml_sax_parser_context.c
135
+ - ext/nokogiri/xml_sax_push_parser.c
136
136
  - ext/nokogiri/xml_attribute_decl.c
137
- - ext/nokogiri/xml_cdata.c
138
- - ext/nokogiri/xml_comment.c
139
- - ext/nokogiri/xml_document.c
140
- - ext/nokogiri/xml_document_fragment.c
141
- - ext/nokogiri/xml_dtd.c
142
- - ext/nokogiri/xml_element_content.c
137
+ - ext/nokogiri/nokogiri.c
143
138
  - ext/nokogiri/xml_element_decl.c
144
- - ext/nokogiri/xml_encoding_handler.c
145
- - ext/nokogiri/xml_entity_decl.c
139
+ - ext/nokogiri/xml_element_content.c
140
+ - ext/nokogiri/html_entity_lookup.c
141
+ - ext/nokogiri/xml_dtd.c
142
+ - ext/nokogiri/xslt_stylesheet.c
143
+ - ext/nokogiri/xml_node_set.c
144
+ - ext/nokogiri/xml_document_fragment.c
145
+ - ext/nokogiri/xml_text.c
146
146
  - ext/nokogiri/xml_entity_reference.c
147
- - ext/nokogiri/xml_io.c
148
- - ext/nokogiri/xml_libxml2_hacks.c
147
+ - ext/nokogiri/html_sax_parser_context.c
148
+ - ext/nokogiri/xml_comment.c
149
149
  - ext/nokogiri/xml_namespace.c
150
+ - ext/nokogiri/xml_entity_decl.c
150
151
  - ext/nokogiri/xml_node.c
151
- - ext/nokogiri/xml_node_set.c
152
- - ext/nokogiri/xml_processing_instruction.c
152
+ - ext/nokogiri/html_document.c
153
+ - ext/nokogiri/xml_syntax_error.c
154
+ - ext/nokogiri/xml_document.c
155
+ - ext/nokogiri/xml_cdata.c
153
156
  - ext/nokogiri/xml_reader.c
154
- - ext/nokogiri/xml_relax_ng.c
155
- - ext/nokogiri/xml_sax_parser.c
156
- - ext/nokogiri/xml_sax_parser_context.c
157
- - ext/nokogiri/xml_sax_push_parser.c
157
+ - ext/nokogiri/xml_attr.c
158
+ - ext/nokogiri/xml_processing_instruction.c
158
159
  - ext/nokogiri/xml_schema.c
159
- - ext/nokogiri/xml_syntax_error.c
160
- - ext/nokogiri/xml_text.c
161
- - ext/nokogiri/xml_xpath_context.c
162
- - ext/nokogiri/xslt_stylesheet.c
160
+ - ext/nokogiri/xml_encoding_handler.c
161
+ - ext/nokogiri/xml_relax_ng.c
163
162
  files:
164
163
  - .autotest
165
164
  - CHANGELOG.ja.rdoc
@@ -276,6 +275,7 @@ files:
276
275
  - lib/nokogiri/ffi/structs/xml_notation.rb
277
276
  - lib/nokogiri/ffi/structs/xml_ns.rb
278
277
  - lib/nokogiri/ffi/structs/xml_parser_context.rb
278
+ - lib/nokogiri/ffi/structs/xml_parser_input.rb
279
279
  - lib/nokogiri/ffi/structs/xml_relax_ng.rb
280
280
  - lib/nokogiri/ffi/structs/xml_sax_handler.rb
281
281
  - lib/nokogiri/ffi/structs/xml_sax_push_parser_context.rb
@@ -368,6 +368,7 @@ files:
368
368
  - test/css/test_parser.rb
369
369
  - test/css/test_tokenizer.rb
370
370
  - test/css/test_xpath_visitor.rb
371
+ - test/decorators/test_slop.rb
371
372
  - test/ffi/test_document.rb
372
373
  - test/files/2ch.html
373
374
  - test/files/address_book.rlx
@@ -440,6 +441,7 @@ files:
440
441
  - test/xml/test_text.rb
441
442
  - test/xml/test_unparented_node.rb
442
443
  - test/xml/test_xpath.rb
444
+ - test/xslt/test_custom_functions.rb
443
445
  has_rdoc: true
444
446
  homepage: http://nokogiri.org
445
447
  licenses: []
@@ -476,60 +478,62 @@ signing_key:
476
478
  specification_version: 3
477
479
  summary: "Nokogiri (\xE9\x8B\xB8) is an HTML, XML, SAX, and Reader parser"
478
480
  test_files:
479
- - test/css/test_nthiness.rb
480
- - test/css/test_parser.rb
481
- - test/css/test_tokenizer.rb
482
- - test/css/test_xpath_visitor.rb
483
- - test/ffi/test_document.rb
484
- - test/html/sax/test_parser.rb
485
- - test/html/sax/test_parser_context.rb
486
- - test/html/test_builder.rb
487
- - test/html/test_document.rb
488
- - test/html/test_document_encoding.rb
489
- - test/html/test_document_fragment.rb
490
- - test/html/test_element_description.rb
491
- - test/html/test_named_characters.rb
492
- - test/html/test_node.rb
493
- - test/html/test_node_encoding.rb
494
- - test/test_convert_xpath.rb
481
+ - test/test_reader.rb
495
482
  - test/test_css_cache.rb
496
483
  - test/test_encoding_handler.rb
484
+ - test/decorators/test_slop.rb
497
485
  - test/test_memory_leak.rb
498
- - test/test_nokogiri.rb
499
- - test/test_reader.rb
500
- - test/test_soap4r_sax.rb
501
- - test/test_xslt_transforms.rb
502
- - test/xml/node/test_save_options.rb
503
- - test/xml/node/test_subclass.rb
504
- - test/xml/sax/test_parser.rb
505
- - test/xml/sax/test_parser_context.rb
506
- - test/xml/sax/test_push_parser.rb
507
- - test/xml/test_attr.rb
508
- - test/xml/test_attribute_decl.rb
509
- - test/xml/test_builder.rb
486
+ - test/xml/test_document_encoding.rb
487
+ - test/xml/test_relax_ng.rb
488
+ - test/xml/test_text.rb
489
+ - test/xml/test_node_reparenting.rb
490
+ - test/xml/test_syntax_error.rb
491
+ - test/xml/test_unparented_node.rb
492
+ - test/xml/test_node_encoding.rb
493
+ - test/xml/test_reader_encoding.rb
494
+ - test/xml/test_processing_instruction.rb
510
495
  - test/xml/test_cdata.rb
511
- - test/xml/test_comment.rb
496
+ - test/xml/test_node.rb
497
+ - test/xml/test_builder.rb
498
+ - test/xml/test_namespace.rb
512
499
  - test/xml/test_document.rb
513
- - test/xml/test_document_encoding.rb
500
+ - test/xml/test_element_content.rb
514
501
  - test/xml/test_document_fragment.rb
502
+ - test/xml/test_entity_reference.rb
503
+ - test/xml/test_attr.rb
515
504
  - test/xml/test_dtd.rb
516
- - test/xml/test_dtd_encoding.rb
517
- - test/xml/test_element_content.rb
505
+ - test/xml/sax/test_parser.rb
506
+ - test/xml/sax/test_parser_context.rb
507
+ - test/xml/sax/test_push_parser.rb
518
508
  - test/xml/test_element_decl.rb
519
- - test/xml/test_entity_decl.rb
520
- - test/xml/test_entity_reference.rb
521
- - test/xml/test_namespace.rb
522
- - test/xml/test_node.rb
523
509
  - test/xml/test_node_attributes.rb
524
- - test/xml/test_node_encoding.rb
525
- - test/xml/test_node_reparenting.rb
510
+ - test/xml/test_xpath.rb
526
511
  - test/xml/test_node_set.rb
527
512
  - test/xml/test_parse_options.rb
528
- - test/xml/test_processing_instruction.rb
529
- - test/xml/test_reader_encoding.rb
530
- - test/xml/test_relax_ng.rb
513
+ - test/xml/test_entity_decl.rb
514
+ - test/xml/node/test_save_options.rb
515
+ - test/xml/node/test_subclass.rb
516
+ - test/xml/test_attribute_decl.rb
531
517
  - test/xml/test_schema.rb
532
- - test/xml/test_syntax_error.rb
533
- - test/xml/test_text.rb
534
- - test/xml/test_unparented_node.rb
535
- - test/xml/test_xpath.rb
518
+ - test/xml/test_dtd_encoding.rb
519
+ - test/xml/test_comment.rb
520
+ - test/test_nokogiri.rb
521
+ - test/html/test_document_encoding.rb
522
+ - test/html/test_node_encoding.rb
523
+ - test/html/test_node.rb
524
+ - test/html/test_builder.rb
525
+ - test/html/test_document.rb
526
+ - test/html/test_document_fragment.rb
527
+ - test/html/sax/test_parser.rb
528
+ - test/html/sax/test_parser_context.rb
529
+ - test/html/test_named_characters.rb
530
+ - test/html/test_element_description.rb
531
+ - test/ffi/test_document.rb
532
+ - test/test_convert_xpath.rb
533
+ - test/test_soap4r_sax.rb
534
+ - test/css/test_nthiness.rb
535
+ - test/css/test_parser.rb
536
+ - test/css/test_tokenizer.rb
537
+ - test/css/test_xpath_visitor.rb
538
+ - test/xslt/test_custom_functions.rb
539
+ - test/test_xslt_transforms.rb