Skip to content
Browse files

Adding more OEmbed providers

  • Loading branch information...
1 parent d5c475a commit b0619bee30f0b934b7946c6b8001a0af33f636c8 @czarneckid czarneckid committed Jan 18, 2012
Showing with 13 additions and 1 deletion.
  1. +6 −0 lib/oembedr/providers.rb
  2. +7 −1 spec/oembedr/providers_spec.rb
View
6 lib/oembedr/providers.rb
@@ -19,6 +19,12 @@ module Providers
/skitch\.com/ => 'http://skitch.com/oembed',
/twitch\.tv/ => false, # OMG! Support OEmbed!
/twitter\.com/ => 'https://api.twitter.com/1/statuses/oembed.{format}',
+ /dailymotion\.com/ => 'http://www.dailymotion.com/api/oembed/',
+ /scribd\.com/ => 'http://www.scribd.com/services/oembed',
+ /dotsub\.com/ => 'http://dotsub.com/services/oembed',
+ /clikthrough\.com/ => 'http://clikthrough.com/services/oembed',
+ /kinomap\.com/ => 'http://www.kinomap.com/oembed',
+ /photobucket\.com/ => 'http://photobucket.com/oembed'
# ...
}
View
8 spec/oembedr/providers_spec.rb
@@ -37,7 +37,13 @@ module Oembedr
"http://opera.com" => 'http://my.opera.com/service/oembed',
"http://skitch.com/hannaolsen/rq33h/vday" => 'http://skitch.com/oembed',
"http://www.twitch.tv/i_like_turtlez" => false, # OMG! Support OEmbed!
- "https://twitter.com/hypomodern/status/158203918323695616" => 'https://api.twitter.com/1/statuses/oembed.{format}'
+ "https://twitter.com/hypomodern/status/158203918323695616" => 'https://api.twitter.com/1/statuses/oembed.{format}',
+ "http://www.dailymotion.com/video/x5ioet_phoenix-mars-lander_tech" => 'http://www.dailymotion.com/api/oembed/',
+ "http://www.scribd.com/doc/17896323/Indian-Automobile-industryPEST" => 'http://www.scribd.com/services/oembed',
+ "http://dotsub.com/view/10e3cb5e-96c7-4cfb-bcea-8ab11e04e090" => 'http://dotsub.com/services/oembed',
+ "http://www.clikthrough.com/theater/video/55" => 'http://clikthrough.com/services/oembed',
+ "http://www.kinomap.com/kms-vzkpc7" => 'http://www.kinomap.com/oembed',
+ "http://img.photobucket.com/albums/v211/JAV123/Michael%20Holland%20Candle%20Burning/_MG_5661.jpg" => 'http://photobucket.com/oembed'
}.each do |(test_url, expected_value)|
it "should match #{test_url} to #{expected_value}" do
Oembedr.service_endpoint(test_url).should == expected_value

0 comments on commit b0619be

Please sign in to comment.
Something went wrong with that request. Please try again.