saxaphone 0.6.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Rakefile +2 -2
- data/lib/saxaphone/document.rb +5 -0
- data/test/document_test.rb +11 -14
- metadata +9 -13
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 87933c6b8d102bc515762a229a937c9663696d90
|
4
|
+
data.tar.gz: 1e50abcefe7a107bb8eba592e05dbc62a888eecb
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a60eb3e95533bfe17b2d80fd39a2343efc1b960eed59a5148c68a283c0aa610f2799a9c8b19271a28399594da858ba608d7eac6867c8a493dbfaa510d3c4c8c8
|
7
|
+
data.tar.gz: 983a48d3550f2f77fdfe1ddc80fc5c661803d9530b6a8a7237938d5e8d457e9ecbe2faa610d497efedc9ebfc621e30d520d2dbe7255f3da8c0f2ec9ac9b26fc9
|
data/Rakefile
CHANGED
@@ -1,10 +1,9 @@
|
|
1
1
|
require 'rake'
|
2
|
-
require 'rake/testtask'
|
3
|
-
require 'rake/rdoctask'
|
4
2
|
|
5
3
|
desc 'Default: run unit tests.'
|
6
4
|
task :default => :test
|
7
5
|
|
6
|
+
require 'rake/testtask'
|
8
7
|
desc 'Test.'
|
9
8
|
Rake::TestTask.new(:test) do |t|
|
10
9
|
t.libs << 'lib'
|
@@ -13,6 +12,7 @@ Rake::TestTask.new(:test) do |t|
|
|
13
12
|
t.verbose = true
|
14
13
|
end
|
15
14
|
|
15
|
+
require 'rdoc/task'
|
16
16
|
desc 'Generate documentation.'
|
17
17
|
Rake::RDocTask.new(:rdoc) do |rdoc|
|
18
18
|
rdoc.rdoc_dir = 'rdoc'
|
data/lib/saxaphone/document.rb
CHANGED
data/test/document_test.rb
CHANGED
@@ -2,21 +2,18 @@ require 'test_helper'
|
|
2
2
|
|
3
3
|
class Saxaphone::DocumentTest < MiniTest::Spec
|
4
4
|
class TestDocument < Saxaphone::Document
|
5
|
-
class FooElement < Saxaphone::Element
|
6
|
-
end
|
7
|
-
end
|
8
|
-
|
9
|
-
def test_parse_xml
|
10
|
-
# assert false
|
11
5
|
end
|
12
6
|
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
<foo>
|
17
|
-
<hola>como estas</hola>
|
18
|
-
<omg>wtf</omg>
|
19
|
-
</foo>
|
20
|
-
}
|
7
|
+
def test_cdata
|
8
|
+
klass = Class.new Saxaphone::Element do
|
9
|
+
element_attribute 'thoughts'
|
21
10
|
end
|
11
|
+
|
12
|
+
element = klass.parse(StringIO.new %{<?xml version="1.0" encoding="utf-8"?>
|
13
|
+
<foo>
|
14
|
+
<thoughts>Bob is <![CDATA[hungry]]></thoughts>
|
15
|
+
</foo>
|
16
|
+
})
|
17
|
+
assert_equal 'Bob is hungry', element.attributes['thoughts']
|
18
|
+
end
|
22
19
|
end
|
metadata
CHANGED
@@ -1,30 +1,27 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: saxaphone
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.7.0
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Matthew Higgins
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2013-05-03 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: nokogiri
|
16
15
|
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
16
|
requirements:
|
19
|
-
- -
|
17
|
+
- - '>='
|
20
18
|
- !ruby/object:Gem::Version
|
21
19
|
version: '0'
|
22
20
|
type: :runtime
|
23
21
|
prerelease: false
|
24
22
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
23
|
requirements:
|
27
|
-
- -
|
24
|
+
- - '>='
|
28
25
|
- !ruby/object:Gem::Version
|
29
26
|
version: '0'
|
30
27
|
description: Use objects
|
@@ -46,26 +43,25 @@ files:
|
|
46
43
|
- test/test_helper.rb
|
47
44
|
homepage: http://github.com/matthuhiggins/saxaphone
|
48
45
|
licenses: []
|
46
|
+
metadata: {}
|
49
47
|
post_install_message:
|
50
48
|
rdoc_options: []
|
51
49
|
require_paths:
|
52
50
|
- lib
|
53
51
|
required_ruby_version: !ruby/object:Gem::Requirement
|
54
|
-
none: false
|
55
52
|
requirements:
|
56
|
-
- -
|
53
|
+
- - '>='
|
57
54
|
- !ruby/object:Gem::Version
|
58
55
|
version: 1.8.7
|
59
56
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
60
|
-
none: false
|
61
57
|
requirements:
|
62
|
-
- -
|
58
|
+
- - '>='
|
63
59
|
- !ruby/object:Gem::Version
|
64
60
|
version: 1.3.5
|
65
61
|
requirements: []
|
66
62
|
rubyforge_project:
|
67
|
-
rubygems_version:
|
63
|
+
rubygems_version: 2.0.0
|
68
64
|
signing_key:
|
69
|
-
specification_version:
|
65
|
+
specification_version: 4
|
70
66
|
summary: Object Oriented SAX Parsing
|
71
67
|
test_files: []
|