hooloo 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 56502b7cff9ec9dfa46165d62ea6e73415e38a6b
4
- data.tar.gz: 7cbf6ecf7c3deb3613a76ad49ea6df74873cd42a
3
+ metadata.gz: 9f4f095f6794fb08c27b89da708e199b775aacfa
4
+ data.tar.gz: b5cbca03b377ac16a3318c1ecd2cf0b7257852e0
5
5
  SHA512:
6
- metadata.gz: ad5e4de1bc3a9903a29f910cac2d4a99466cb3d821290b62ac60bf5a9033f5f1a0d2d5aff4c4c386c8837925eafe39ffb0137ee0bb9be2ef3fd5c4af2a513982
7
- data.tar.gz: 1ab6415a5bb1ae5088b784b563d7daf477bab6e0be4efc6e5609cef30092c295268e4b87112922cacf105a906d2a0aaa416a2d4235895f88ef20ecff90f190ed
6
+ metadata.gz: ceb4f432f0f795e0731cf84a3b2c51aedb7357493f884c5cf43242737a5cd70ebedb08fc8b66a34021f72b868a25395cdad4cdf0b94bc710b890740f53f9b192
7
+ data.tar.gz: 693349abfc7048bfa83e5abf7694326b33aa16feb11bc6d95af520fd2467effb58a2e1329a874245c0d5ddbe3e66b150d371ab014ffa58f0ef00298dd80fe25b
data/Rakefile CHANGED
@@ -2,7 +2,6 @@ require 'bundler/gem_tasks'
2
2
  require 'rake/testtask'
3
3
 
4
4
  Rake::TestTask.new do |t|
5
- rm_rf 'coverage/'
6
5
  t.pattern = 'spec/**/*_spec.rb'
7
6
  t.libs << 'spec'
8
7
  end
@@ -1,3 +1,3 @@
1
1
  class Hooloo
2
- VERSION = "0.1.1"
2
+ VERSION = "0.2.0"
3
3
  end
@@ -6,6 +6,9 @@ class Hooloo::Video < Hooloo::MozartHash
6
6
  @obj = Hooloo.request("videos/#{id}")['data'][0]['video']
7
7
  end
8
8
  end
9
+ def oembed
10
+ Hooloo.request '/api/oembed.json', url: "http://www.hulu.com/watch/#{@obj['id']}"
11
+ end
9
12
  def copyright
10
13
  @obj['copyright'].split(',').map(&:strip)
11
14
  end
@@ -7,4 +7,10 @@ describe Hooloo::Video do
7
7
  video.copyright.must_be_instance_of Array
8
8
  video.copyright.must_include "Reki Kawahara"
9
9
  end
10
+ it 'should retrieve the oembed data' do
11
+ video.oembed.must_be_instance_of Hash
12
+ video.oembed.must_include 'title'
13
+ video.oembed.must_include 'thumbnail_url'
14
+ video.oembed.must_include 'large_thumbnail_url'
15
+ end
10
16
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hooloo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Lejeck
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-10 00:00:00.000000000 Z
11
+ date: 2014-08-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: multi_json