ruby-oembed 0.8.1 → 0.8.3
Sign up to get free protection for your applications and to get access to all the features.
- data/.yardopts +4 -0
- data/CHANGELOG.rdoc +13 -1
- data/Gemfile +9 -4
- data/Gemfile.lock +15 -22
- data/README.rdoc +20 -4
- data/Rakefile +1 -4
- data/lib/oembed/formatter.rb +18 -13
- data/lib/oembed/formatter/base.rb +108 -0
- data/lib/oembed/formatter/json.rb +14 -37
- data/lib/oembed/formatter/json/backends/activesupportjson.rb +8 -8
- data/lib/oembed/formatter/json/backends/jsongem.rb +8 -8
- data/lib/oembed/formatter/json/backends/yaml.rb +11 -11
- data/lib/oembed/formatter/xml.rb +20 -44
- data/lib/oembed/formatter/xml/backends/rexml.rb +10 -10
- data/lib/oembed/formatter/xml/backends/xmlsimple.rb +10 -10
- data/lib/oembed/providers.rb +36 -4
- data/lib/oembed/providers/embedly_urls.yml +58 -10
- data/lib/oembed/version.rb +1 -1
- data/ruby-oembed.gemspec +58 -62
- data/spec/formatter/ducktype_backend_spec.rb +94 -0
- data/spec/formatter/json/.DS_Store +0 -0
- data/spec/formatter/json/jsongem_backend_spec.rb +24 -0
- data/spec/formatter/json/yaml_backend_spec.rb +24 -0
- data/spec/formatter/xml/rexml_backend_spec.rb +24 -0
- data/spec/formatter/xml/xmlsimple_backend_spec.rb +24 -0
- data/spec/spec_helper.rb +28 -0
- metadata +68 -25
- data/.gitignore +0 -5
data/lib/oembed/version.rb
CHANGED
data/ruby-oembed.gemspec
CHANGED
@@ -1,99 +1,95 @@
|
|
1
1
|
# Generated by jeweler
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in Rakefile, and run
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{ruby-oembed}
|
8
|
-
s.version = "0.8.
|
8
|
+
s.version = "0.8.3"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Magnus Holm", "Alex Kessinger", "Aris Bartee", "Marcos Wright Kuhns"]
|
12
|
-
s.date = %q{2011-
|
12
|
+
s.date = %q{2011-06-26}
|
13
13
|
s.description = %q{An oEmbed consumer library written in Ruby, letting you easily get embeddable HTML representations of supported web pages, based on their URLs. See http://oembed.com for more information about the protocol.}
|
14
14
|
s.email = %q{arisbartee@gmail.com}
|
15
15
|
s.extra_rdoc_files = [
|
16
16
|
"LICENSE",
|
17
|
-
|
17
|
+
"README.rdoc"
|
18
18
|
]
|
19
19
|
s.files = [
|
20
|
-
".
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
20
|
+
".rvmrc",
|
21
|
+
".yardopts",
|
22
|
+
"CHANGELOG.rdoc",
|
23
|
+
"Gemfile",
|
24
|
+
"Gemfile.lock",
|
25
|
+
"LICENSE",
|
26
|
+
"README.rdoc",
|
27
|
+
"Rakefile",
|
28
|
+
"integration_test/test.rb",
|
29
|
+
"integration_test/test_urls.csv",
|
30
|
+
"lib/oembed.rb",
|
31
|
+
"lib/oembed/errors.rb",
|
32
|
+
"lib/oembed/formatter.rb",
|
33
|
+
"lib/oembed/formatter/base.rb",
|
34
|
+
"lib/oembed/formatter/json.rb",
|
35
|
+
"lib/oembed/formatter/json/backends/activesupportjson.rb",
|
36
|
+
"lib/oembed/formatter/json/backends/jsongem.rb",
|
37
|
+
"lib/oembed/formatter/json/backends/yaml.rb",
|
38
|
+
"lib/oembed/formatter/xml.rb",
|
39
|
+
"lib/oembed/formatter/xml/backends/rexml.rb",
|
40
|
+
"lib/oembed/formatter/xml/backends/xmlsimple.rb",
|
41
|
+
"lib/oembed/provider.rb",
|
42
|
+
"lib/oembed/provider_discovery.rb",
|
43
|
+
"lib/oembed/providers.rb",
|
44
|
+
"lib/oembed/providers/embedly_urls.yml",
|
45
|
+
"lib/oembed/providers/oohembed_urls.yml",
|
46
|
+
"lib/oembed/response.rb",
|
47
|
+
"lib/oembed/response/link.rb",
|
48
|
+
"lib/oembed/response/photo.rb",
|
49
|
+
"lib/oembed/response/rich.rb",
|
50
|
+
"lib/oembed/response/video.rb",
|
51
|
+
"lib/oembed/version.rb",
|
52
|
+
"lib/tasks/oembed.rake",
|
53
|
+
"lib/tasks/rspec.rake",
|
54
|
+
"ruby-oembed.gemspec",
|
55
|
+
"spec/formatter/ducktype_backend_spec.rb",
|
56
|
+
"spec/formatter/json/.DS_Store",
|
57
|
+
"spec/formatter/json/jsongem_backend_spec.rb",
|
58
|
+
"spec/formatter/json/yaml_backend_spec.rb",
|
59
|
+
"spec/formatter/xml/rexml_backend_spec.rb",
|
60
|
+
"spec/formatter/xml/xmlsimple_backend_spec.rb",
|
61
|
+
"spec/formatter_spec.rb",
|
62
|
+
"spec/provider_spec.rb",
|
63
|
+
"spec/providers_spec.rb",
|
64
|
+
"spec/response_spec.rb",
|
65
|
+
"spec/spec_helper.rb"
|
64
66
|
]
|
65
67
|
s.homepage = %q{http://github.com/judofyr/ruby-oembed}
|
66
68
|
s.licenses = ["MIT"]
|
67
|
-
s.rdoc_options = ["--main", "README.rdoc", "--title", "ruby-oembed-0.8.
|
69
|
+
s.rdoc_options = ["--main", "README.rdoc", "--title", "ruby-oembed-0.8.3", "--inline-source", "--exclude", "tasks", "CHANGELOG.rdoc"]
|
68
70
|
s.require_paths = ["lib"]
|
69
|
-
s.rubygems_version = %q{1.
|
71
|
+
s.rubygems_version = %q{1.4.2}
|
70
72
|
s.summary = %q{oEmbed for Ruby}
|
71
|
-
s.test_files = [
|
72
|
-
"spec/formatter/json/jsongem_backend_spec.rb",
|
73
|
-
"spec/formatter/json/yaml_backend_spec.rb",
|
74
|
-
"spec/formatter/xml/rexml_backend_spec.rb",
|
75
|
-
"spec/formatter/xml/xmlsimple_backend_spec.rb",
|
76
|
-
"spec/formatter_spec.rb",
|
77
|
-
"spec/provider_spec.rb",
|
78
|
-
"spec/providers_spec.rb",
|
79
|
-
"spec/response_spec.rb",
|
80
|
-
"spec/spec_helper.rb"
|
81
|
-
]
|
82
73
|
|
83
74
|
if s.respond_to? :specification_version then
|
84
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
85
75
|
s.specification_version = 3
|
86
76
|
|
87
77
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
78
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
79
|
+
s.add_development_dependency(%q<rake>, [">= 0"])
|
88
80
|
s.add_development_dependency(%q<json>, [">= 0"])
|
89
81
|
s.add_development_dependency(%q<xml-simple>, [">= 0"])
|
90
82
|
s.add_development_dependency(%q<rspec>, [">= 2.0"])
|
91
83
|
else
|
84
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
85
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
92
86
|
s.add_dependency(%q<json>, [">= 0"])
|
93
87
|
s.add_dependency(%q<xml-simple>, [">= 0"])
|
94
88
|
s.add_dependency(%q<rspec>, [">= 2.0"])
|
95
89
|
end
|
96
90
|
else
|
91
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
92
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
97
93
|
s.add_dependency(%q<json>, [">= 0"])
|
98
94
|
s.add_dependency(%q<xml-simple>, [">= 0"])
|
99
95
|
s.add_dependency(%q<rspec>, [">= 2.0"])
|
@@ -0,0 +1,94 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/../spec_helper'
|
2
|
+
|
3
|
+
class WorkingDuck
|
4
|
+
# The WorkingDuck Class should work as a Backend
|
5
|
+
class << self
|
6
|
+
# Fakes a correct deocde response
|
7
|
+
def decode(value)
|
8
|
+
{"version"=>1.0, "string"=>"test", "int"=>42, "html"=>"<i>Cool's</i>\n the \"word\"!",}
|
9
|
+
end
|
10
|
+
def parse_error; RuntimeError; end
|
11
|
+
end
|
12
|
+
|
13
|
+
# A WorkingDuck instance should work as a Backend
|
14
|
+
def decode(value)
|
15
|
+
self.class.decode(value)
|
16
|
+
end
|
17
|
+
def parse_error; RuntimeError; end
|
18
|
+
end
|
19
|
+
|
20
|
+
class FailingDuckDecode
|
21
|
+
# Fakes an incorrect decode response
|
22
|
+
def decode(value)
|
23
|
+
{}
|
24
|
+
end
|
25
|
+
def parse_error; RuntimeError; end
|
26
|
+
end
|
27
|
+
|
28
|
+
describe "OEmbed::Formatter::JSON::Backends::DuckType" do
|
29
|
+
include OEmbedSpecHelper
|
30
|
+
|
31
|
+
it "should work with WorkingDuck Class" do
|
32
|
+
lambda {
|
33
|
+
OEmbed::Formatter::JSON.backend = WorkingDuck
|
34
|
+
}.should_not raise_error
|
35
|
+
OEmbed::Formatter::JSON.backend.should equal(WorkingDuck)
|
36
|
+
end
|
37
|
+
|
38
|
+
it "should work with a WorkingDuck instance" do
|
39
|
+
instance = WorkingDuck.new
|
40
|
+
lambda {
|
41
|
+
OEmbed::Formatter::JSON.backend = instance
|
42
|
+
}.should_not raise_error
|
43
|
+
OEmbed::Formatter::JSON.backend.should equal(instance)
|
44
|
+
end
|
45
|
+
|
46
|
+
it "should fail with FailingDuckDecode Class" do
|
47
|
+
lambda {
|
48
|
+
OEmbed::Formatter::JSON.backend = FailingDuckDecode
|
49
|
+
}.should raise_error(LoadError)
|
50
|
+
OEmbed::Formatter::JSON.backend.should_not equal(FailingDuckDecode)
|
51
|
+
end
|
52
|
+
|
53
|
+
it "should fail with a FailingDuckDecode instance" do
|
54
|
+
instance = FailingDuckDecode.new
|
55
|
+
lambda {
|
56
|
+
OEmbed::Formatter::JSON.backend = instance
|
57
|
+
}.should raise_error(LoadError)
|
58
|
+
OEmbed::Formatter::JSON.backend.should_not equal(instance)
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
describe "OEmbed::Formatter::XML::Backends::DuckType" do
|
63
|
+
include OEmbedSpecHelper
|
64
|
+
|
65
|
+
it "should work with WorkingDuck Class" do
|
66
|
+
lambda {
|
67
|
+
OEmbed::Formatter::XML.backend = WorkingDuck
|
68
|
+
}.should_not raise_error
|
69
|
+
OEmbed::Formatter::XML.backend.should equal(WorkingDuck)
|
70
|
+
end
|
71
|
+
|
72
|
+
it "should work with a WorkingDuck instance" do
|
73
|
+
instance = WorkingDuck.new
|
74
|
+
lambda {
|
75
|
+
OEmbed::Formatter::XML.backend = instance
|
76
|
+
}.should_not raise_error
|
77
|
+
OEmbed::Formatter::XML.backend.should equal(instance)
|
78
|
+
end
|
79
|
+
|
80
|
+
it "should fail with FailingDuckDecode Class" do
|
81
|
+
lambda {
|
82
|
+
OEmbed::Formatter::XML.backend = FailingDuckDecode
|
83
|
+
}.should raise_error(LoadError)
|
84
|
+
OEmbed::Formatter::XML.backend.should_not equal(FailingDuckDecode)
|
85
|
+
end
|
86
|
+
|
87
|
+
it "should fail with a FailingDuckDecode instance" do
|
88
|
+
instance = FailingDuckDecode.new
|
89
|
+
lambda {
|
90
|
+
OEmbed::Formatter::XML.backend = instance
|
91
|
+
}.should raise_error(LoadError)
|
92
|
+
OEmbed::Formatter::XML.backend.should_not equal(instance)
|
93
|
+
end
|
94
|
+
end
|
Binary file
|
@@ -31,4 +31,28 @@ describe "OEmbed::Formatter::JSON::Backends::JSONGem" do
|
|
31
31
|
decoded.keys.should == valid_response(:object).keys
|
32
32
|
decoded.values.map{|v|v.to_s}.should == valid_response(:object).values.map{|v|v.to_s}
|
33
33
|
end
|
34
|
+
|
35
|
+
it "should raise an OEmbed::ParseError when decoding an invalid JSON String" do
|
36
|
+
lambda {
|
37
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('unclosed_container', :json))
|
38
|
+
}.should raise_error(OEmbed::ParseError)
|
39
|
+
lambda {
|
40
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('unclosed_tag', :json))
|
41
|
+
}.should raise_error(OEmbed::ParseError)
|
42
|
+
lambda {
|
43
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('invalid_syntax', :json))
|
44
|
+
}.should raise_error(OEmbed::ParseError)
|
45
|
+
end
|
46
|
+
|
47
|
+
it "should raise an OEmbed::ParseError when decoding fails with an unexpected error" do
|
48
|
+
error_to_raise = ArgumentError
|
49
|
+
OEmbed::Formatter::JSON.backend.parse_error.should_not be_kind_of(error_to_raise)
|
50
|
+
|
51
|
+
::JSON.should_receive(:parse).
|
52
|
+
and_raise(error_to_raise.new("unknown error"))
|
53
|
+
|
54
|
+
lambda {
|
55
|
+
decode = OEmbed::Formatter.decode(:json, valid_response(:json))
|
56
|
+
}.should raise_error(OEmbed::ParseError)
|
57
|
+
end
|
34
58
|
end
|
@@ -27,4 +27,28 @@ describe "OEmbed::Formatter::JSON::Backends::Yaml" do
|
|
27
27
|
decoded.keys.should == valid_response(:object).keys
|
28
28
|
decoded.values.map{|v|v.to_s}.should == valid_response(:object).values.map{|v|v.to_s}
|
29
29
|
end
|
30
|
+
|
31
|
+
it "should raise an OEmbed::ParseError when decoding an invalid JSON String" do
|
32
|
+
lambda {
|
33
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('unclosed_container', :json))
|
34
|
+
}.should raise_error(OEmbed::ParseError)
|
35
|
+
lambda {
|
36
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('unclosed_tag', :json))
|
37
|
+
}.should raise_error(OEmbed::ParseError)
|
38
|
+
lambda {
|
39
|
+
decode = OEmbed::Formatter.decode(:json, invalid_response('invalid_syntax', :json))
|
40
|
+
}.should raise_error(OEmbed::ParseError)
|
41
|
+
end
|
42
|
+
|
43
|
+
it "should raise an OEmbed::ParseError when decoding fails with an unexpected error" do
|
44
|
+
error_to_raise = ArgumentError
|
45
|
+
OEmbed::Formatter::JSON.backend.parse_error.should_not be_kind_of(error_to_raise)
|
46
|
+
|
47
|
+
OEmbed::Formatter::JSON.backend.should_receive(:convert_json_to_yaml).
|
48
|
+
and_raise(error_to_raise.new("unknown error"))
|
49
|
+
|
50
|
+
lambda {
|
51
|
+
decode = OEmbed::Formatter.decode(:json, valid_response(:json))
|
52
|
+
}.should raise_error(OEmbed::ParseError)
|
53
|
+
end
|
30
54
|
end
|
@@ -27,4 +27,28 @@ describe "OEmbed::Formatter::XML::Backends::REXML" do
|
|
27
27
|
decoded.keys.should == valid_response(:object).keys
|
28
28
|
decoded.values.map{|v|v.to_s}.should == valid_response(:object).values.map{|v|v.to_s}
|
29
29
|
end
|
30
|
+
|
31
|
+
it "should raise an OEmbed::ParseError when decoding an invalid XML String" do
|
32
|
+
lambda {
|
33
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('unclosed_container', :xml))
|
34
|
+
}.should raise_error(OEmbed::ParseError)
|
35
|
+
lambda {
|
36
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('unclosed_tag', :xml))
|
37
|
+
}.should raise_error(OEmbed::ParseError)
|
38
|
+
lambda {
|
39
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('invalid_syntax', :xml))
|
40
|
+
}.should raise_error(OEmbed::ParseError)
|
41
|
+
end
|
42
|
+
|
43
|
+
it "should raise an OEmbed::ParseError when decoding fails with an unexpected error" do
|
44
|
+
error_to_raise = ArgumentError
|
45
|
+
OEmbed::Formatter::XML.backend.parse_error.should_not be_kind_of(error_to_raise)
|
46
|
+
|
47
|
+
::REXML::Document.should_receive(:new).
|
48
|
+
and_raise(error_to_raise.new("unknown error"))
|
49
|
+
|
50
|
+
lambda {
|
51
|
+
decode = OEmbed::Formatter.decode(:xml, valid_response(:xml))
|
52
|
+
}.should raise_error(OEmbed::ParseError)
|
53
|
+
end
|
30
54
|
end
|
@@ -31,4 +31,28 @@ describe "OEmbed::Formatter::XML::Backends::XmlSimple" do
|
|
31
31
|
decoded.keys.should == valid_response(:object).keys
|
32
32
|
decoded.values.map{|v|v.to_s}.should == valid_response(:object).values.map{|v|v.to_s}
|
33
33
|
end
|
34
|
+
|
35
|
+
it "should raise an OEmbed::ParseError when decoding an invalid XML String" do
|
36
|
+
lambda {
|
37
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('unclosed_container', :xml))
|
38
|
+
}.should raise_error(OEmbed::ParseError)
|
39
|
+
lambda {
|
40
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('unclosed_tag', :xml))
|
41
|
+
}.should raise_error(OEmbed::ParseError)
|
42
|
+
lambda {
|
43
|
+
decode = OEmbed::Formatter.decode(:xml, invalid_response('invalid_syntax', :xml))
|
44
|
+
}.should raise_error(OEmbed::ParseError)
|
45
|
+
end
|
46
|
+
|
47
|
+
it "should raise an OEmbed::ParseError when decoding fails with an unexpected error" do
|
48
|
+
error_to_raise = ArgumentError
|
49
|
+
OEmbed::Formatter::XML.backend.parse_error.should_not be_kind_of(error_to_raise)
|
50
|
+
|
51
|
+
::XmlSimple.should_receive(:xml_in).
|
52
|
+
and_raise(error_to_raise.new("unknown error"))
|
53
|
+
|
54
|
+
lambda {
|
55
|
+
decode = OEmbed::Formatter.decode(:xml, valid_response(:xml))
|
56
|
+
}.should raise_error(OEmbed::ParseError)
|
57
|
+
end
|
34
58
|
end
|
data/spec/spec_helper.rb
CHANGED
@@ -65,4 +65,32 @@ module OEmbedSpecHelper
|
|
65
65
|
XML
|
66
66
|
end
|
67
67
|
end
|
68
|
+
|
69
|
+
def invalid_response(case_name, format)
|
70
|
+
format = format.to_s
|
71
|
+
valid = valid_response(format)
|
72
|
+
case case_name.to_s
|
73
|
+
when 'unclosed_container'
|
74
|
+
case format
|
75
|
+
when 'json'
|
76
|
+
valid_response(format).gsub(/\}\s*\z/, '')
|
77
|
+
when 'xml'
|
78
|
+
valid_response(format).gsub(%r{</oembed[^>]*>}, '')
|
79
|
+
end
|
80
|
+
when 'unclosed_tag'
|
81
|
+
case format
|
82
|
+
when 'json'
|
83
|
+
valid_response(format).gsub('"photo"', '"photo')
|
84
|
+
when 'xml'
|
85
|
+
valid_response(format).gsub('</type>', '')
|
86
|
+
end
|
87
|
+
when 'invalid_syntax'
|
88
|
+
case format
|
89
|
+
when 'json'
|
90
|
+
valid_response(format).gsub('"type"', '"type":')
|
91
|
+
when 'xml'
|
92
|
+
valid_response(format).gsub('type', 'ty><pe')
|
93
|
+
end
|
94
|
+
end
|
95
|
+
end
|
68
96
|
end
|
metadata
CHANGED
@@ -1,8 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-oembed
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
+
hash: 57
|
4
5
|
prerelease:
|
5
|
-
|
6
|
+
segments:
|
7
|
+
- 0
|
8
|
+
- 8
|
9
|
+
- 3
|
10
|
+
version: 0.8.3
|
6
11
|
platform: ruby
|
7
12
|
authors:
|
8
13
|
- Magnus Holm
|
@@ -13,42 +18,80 @@ autorequire:
|
|
13
18
|
bindir: bin
|
14
19
|
cert_chain: []
|
15
20
|
|
16
|
-
date: 2011-
|
21
|
+
date: 2011-06-26 00:00:00 -07:00
|
17
22
|
default_executable:
|
18
23
|
dependencies:
|
19
24
|
- !ruby/object:Gem::Dependency
|
20
|
-
|
21
|
-
prerelease: false
|
22
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
version_requirements: &id001 !ruby/object:Gem::Requirement
|
23
26
|
none: false
|
24
27
|
requirements:
|
25
28
|
- - ">="
|
26
29
|
- !ruby/object:Gem::Version
|
30
|
+
hash: 3
|
31
|
+
segments:
|
32
|
+
- 0
|
27
33
|
version: "0"
|
34
|
+
name: jeweler
|
35
|
+
prerelease: false
|
28
36
|
type: :development
|
29
|
-
|
37
|
+
requirement: *id001
|
30
38
|
- !ruby/object:Gem::Dependency
|
31
|
-
|
39
|
+
version_requirements: &id002 !ruby/object:Gem::Requirement
|
40
|
+
none: false
|
41
|
+
requirements:
|
42
|
+
- - ">="
|
43
|
+
- !ruby/object:Gem::Version
|
44
|
+
hash: 3
|
45
|
+
segments:
|
46
|
+
- 0
|
47
|
+
version: "0"
|
48
|
+
name: rake
|
32
49
|
prerelease: false
|
33
|
-
|
50
|
+
type: :development
|
51
|
+
requirement: *id002
|
52
|
+
- !ruby/object:Gem::Dependency
|
53
|
+
version_requirements: &id003 !ruby/object:Gem::Requirement
|
34
54
|
none: false
|
35
55
|
requirements:
|
36
56
|
- - ">="
|
37
57
|
- !ruby/object:Gem::Version
|
58
|
+
hash: 3
|
59
|
+
segments:
|
60
|
+
- 0
|
38
61
|
version: "0"
|
62
|
+
name: json
|
63
|
+
prerelease: false
|
39
64
|
type: :development
|
40
|
-
|
65
|
+
requirement: *id003
|
41
66
|
- !ruby/object:Gem::Dependency
|
42
|
-
|
67
|
+
version_requirements: &id004 !ruby/object:Gem::Requirement
|
68
|
+
none: false
|
69
|
+
requirements:
|
70
|
+
- - ">="
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
hash: 3
|
73
|
+
segments:
|
74
|
+
- 0
|
75
|
+
version: "0"
|
76
|
+
name: xml-simple
|
43
77
|
prerelease: false
|
44
|
-
|
78
|
+
type: :development
|
79
|
+
requirement: *id004
|
80
|
+
- !ruby/object:Gem::Dependency
|
81
|
+
version_requirements: &id005 !ruby/object:Gem::Requirement
|
45
82
|
none: false
|
46
83
|
requirements:
|
47
84
|
- - ">="
|
48
85
|
- !ruby/object:Gem::Version
|
86
|
+
hash: 3
|
87
|
+
segments:
|
88
|
+
- 2
|
89
|
+
- 0
|
49
90
|
version: "2.0"
|
91
|
+
name: rspec
|
92
|
+
prerelease: false
|
50
93
|
type: :development
|
51
|
-
|
94
|
+
requirement: *id005
|
52
95
|
description: An oEmbed consumer library written in Ruby, letting you easily get embeddable HTML representations of supported web pages, based on their URLs. See http://oembed.com for more information about the protocol.
|
53
96
|
email: arisbartee@gmail.com
|
54
97
|
executables: []
|
@@ -59,8 +102,8 @@ extra_rdoc_files:
|
|
59
102
|
- LICENSE
|
60
103
|
- README.rdoc
|
61
104
|
files:
|
62
|
-
- .gitignore
|
63
105
|
- .rvmrc
|
106
|
+
- .yardopts
|
64
107
|
- CHANGELOG.rdoc
|
65
108
|
- Gemfile
|
66
109
|
- Gemfile.lock
|
@@ -72,6 +115,7 @@ files:
|
|
72
115
|
- lib/oembed.rb
|
73
116
|
- lib/oembed/errors.rb
|
74
117
|
- lib/oembed/formatter.rb
|
118
|
+
- lib/oembed/formatter/base.rb
|
75
119
|
- lib/oembed/formatter/json.rb
|
76
120
|
- lib/oembed/formatter/json/backends/activesupportjson.rb
|
77
121
|
- lib/oembed/formatter/json/backends/jsongem.rb
|
@@ -93,6 +137,7 @@ files:
|
|
93
137
|
- lib/tasks/oembed.rake
|
94
138
|
- lib/tasks/rspec.rake
|
95
139
|
- ruby-oembed.gemspec
|
140
|
+
- spec/formatter/ducktype_backend_spec.rb
|
96
141
|
- spec/formatter/json/.DS_Store
|
97
142
|
- spec/formatter/json/jsongem_backend_spec.rb
|
98
143
|
- spec/formatter/json/yaml_backend_spec.rb
|
@@ -112,7 +157,7 @@ rdoc_options:
|
|
112
157
|
- --main
|
113
158
|
- README.rdoc
|
114
159
|
- --title
|
115
|
-
- ruby-oembed-0.8.
|
160
|
+
- ruby-oembed-0.8.3
|
116
161
|
- --inline-source
|
117
162
|
- --exclude
|
118
163
|
- tasks
|
@@ -124,27 +169,25 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
124
169
|
requirements:
|
125
170
|
- - ">="
|
126
171
|
- !ruby/object:Gem::Version
|
172
|
+
hash: 3
|
173
|
+
segments:
|
174
|
+
- 0
|
127
175
|
version: "0"
|
128
176
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
129
177
|
none: false
|
130
178
|
requirements:
|
131
179
|
- - ">="
|
132
180
|
- !ruby/object:Gem::Version
|
181
|
+
hash: 3
|
182
|
+
segments:
|
183
|
+
- 0
|
133
184
|
version: "0"
|
134
185
|
requirements: []
|
135
186
|
|
136
187
|
rubyforge_project:
|
137
|
-
rubygems_version: 1.
|
188
|
+
rubygems_version: 1.4.2
|
138
189
|
signing_key:
|
139
190
|
specification_version: 3
|
140
191
|
summary: oEmbed for Ruby
|
141
|
-
test_files:
|
142
|
-
|
143
|
-
- spec/formatter/json/yaml_backend_spec.rb
|
144
|
-
- spec/formatter/xml/rexml_backend_spec.rb
|
145
|
-
- spec/formatter/xml/xmlsimple_backend_spec.rb
|
146
|
-
- spec/formatter_spec.rb
|
147
|
-
- spec/provider_spec.rb
|
148
|
-
- spec/providers_spec.rb
|
149
|
-
- spec/response_spec.rb
|
150
|
-
- spec/spec_helper.rb
|
192
|
+
test_files: []
|
193
|
+
|