yt 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 267ed97d1f7857b28aa9577a8e5b06f30beb6d49
4
- data.tar.gz: 7ebaddc635450434a4087c1bff77c25b5721c1ae
3
+ metadata.gz: 597c8d1060669465155d5b6cdbf04682794ddf76
4
+ data.tar.gz: f1e05002580e40cda83959e07596f8e795ef4463
5
5
  SHA512:
6
- metadata.gz: d5e4615ed9ec50327686a37c2a4f1c8b4cd1646666e841d0d2e1ebaf0aece040fe2da04793642a010d0293996e2c960cd284711e214a76f1d912b2ac8fdd22a4
7
- data.tar.gz: d7694945db65f5cf0a5287473c1a18184cdec831fca1714bba6b286fef841acf766134108fb7cc724ad4170d696d82eaf3fa184d0a802aec50c25cf79774163f
6
+ metadata.gz: 0ddb3a60ddd30f3b71ea52d61f2b05ca1931cc7a26d7ef033afdcc04eff90a2628fd0689ea9e078ae2d1377e6d00a654d7ce5925d2aa1f1a0cfb3b8492c475b1
7
+ data.tar.gz: a65c07e1a208e1ed06cf7674980826fd0d4deacfb879a358fcee8adac80b85753778d8f0ae93af93c157489a880d0b87f2307621571a2901ec3331ccc1e9e589
data/.travis.yml CHANGED
@@ -5,6 +5,7 @@ notifications:
5
5
  email: false
6
6
  env:
7
7
  global:
8
- secure: FC19i/qIjqV7dzd8bZS+yc5HC3XbssU/lBn7+pNsfhsXZp2FpZ4u3v2HPCRZPZ7IsCpsLtUraq6rub290dXecEr1gzSwmaMdfvJz8f2lr1YR58BF9xnTwBUinZOcv9auhWHwCzYRQMHyILUa2NvmVqq0QzYbWVa9X1gwejqyoaQ=
9
- matrix:
10
- secure: EX0FinqK+va3hTUWNVk7HeFIZqwC0OFlmvW7GX+vJ//vs1Bvsqxqbo1bdqwieMVYxcRwt9cOZU8QapPPc4+v7Awo7ASCgNUo4Y7yrIkjfQdY6b2UyPo6yJw7+Mcyj9gej5hD0mBm+E/KCvvirVfDXfWedPy3Z1FovK1sVW9RqPs=
8
+ - secure: UPTXrTnEtwOW3MZLjGmKmllUflKEQ9ICjELS5j3ucScIyW+q8idf7EEuj03n2FKN/zGNo1BDxLbMxzh+1jBhugGxIF0gmSXQ4tborLMkYtQ07rAWemHGCx3RicDlAWSuqz9tDkMILsasK74LgbfaEeJYI6xfAvOm+em/7jxUk5w=
9
+ - secure: Gkg2vV9NFxvA6TUpl4d10HZNtYB2j1qP5nwlIWuDwV79Wbst2u+sgUX6nCTcQA1L4EgHQqfXXM6NHUrLevT45kj6DuG2C/sJUudttqfB5VmfK7nNT617BlqgiZuNjNWCnD9CK5zAdHUo2ukxiXKyl/WhYIhBA59fsGbFynbUISM=
10
+ - secure: RLWA00fvwiyk2JooX+ePrwPfUCWE1aunuA9STogRiwwUYO237lU35hDkuE7+0GMJAtfWDkuG5f4+8oWsOf0sBytebgxhJ25Uxi6uWlsukuXRM028Z8yjMzgLzmke5InICIVKzPWyvjlphB14nP4PoSrPl9RlHgs4LuJ4l/OkbEQ=
11
+ - secure: RuYxzoTiam6GLIoP3xkhU9eaW3kjyxnOLYqBjjezhEHXrExDQinO5/k2NsHy2Y8iZSlKxMAG+DJJ45WAObNpg3fAPC/ExrzGyNX1u3qCQU481HbVZTJa8vg9IrJsSxCYyawdcbd7tgULiuRZacMmamsXLSJymLofF7LE0jA2KPA=
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- yt (0.4.0)
4
+ yt (0.4.1)
5
5
  activesupport
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -276,7 +276,7 @@ To install on your system, run
276
276
 
277
277
  To use inside a bundled Ruby project, add this line to the Gemfile:
278
278
 
279
- gem 'yt', '~> 0.4.0'
279
+ gem 'yt', '~> 0.4.1'
280
280
 
281
281
  Since the gem follows [Semantic Versioning](http://semver.org),
282
282
  indicating the full version in your Gemfile (~> *major*.*minor*.*patch*)
data/Rakefile CHANGED
@@ -1 +1,11 @@
1
- require "bundler/gem_tasks"
1
+ require "bundler"
2
+ Bundler.setup
3
+ Bundler::GemHelper.install_tasks
4
+
5
+ require "rspec/core/rake_task"
6
+ require "rspec/core/version"
7
+
8
+ desc "Run all examples"
9
+ RSpec::Core::RakeTask.new :spec
10
+
11
+ task default: [:spec]
@@ -4,7 +4,7 @@ module Yt
4
4
  module Actions
5
5
  module List
6
6
 
7
- delegate :count, :first, :any?, :each, :map, to: :list
7
+ delegate :count, :first, :any?, :each, :map, :find, to: :list
8
8
  alias size count
9
9
 
10
10
  private
@@ -36,7 +36,7 @@ module Yt
36
36
  # To overcome this, if we have just updated the subscription, we must
37
37
  # wait some time before requesting it again.
38
38
  #
39
- def throttle(seconds = 8)
39
+ def throttle(seconds = 9)
40
40
  wait = [(@last_changed_at ||= Time.now) - Time.now + seconds, 0].max
41
41
  sleep wait
42
42
  @last_changed_at = Time.now
data/lib/yt/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Yt
2
- VERSION = '0.4.0'
2
+ VERSION = '0.4.1'
3
3
  end
@@ -5,6 +5,6 @@ describe Yt::Associations::Channels, scenario: :device_app do
5
5
  let(:account) { Yt.configuration.account }
6
6
 
7
7
  describe '#channel' do
8
- it { require 'pry'; binding.pry; true; expect(account.channel).to be_a Yt::Channel }
8
+ it { expect(account.channel).to be_a Yt::Channel }
9
9
  end
10
10
  end
@@ -14,7 +14,7 @@ describe Yt::Associations::PlaylistItems, scenario: :device_app do
14
14
  # TODO: after, delete playlist item
15
15
 
16
16
  it { expect(@playlist.playlist_items.count).to be > 0 }
17
- it { require 'pry'; binding.pry; true; expect(@playlist.playlist_items.first).to be_a Yt::PlaylistItem }
17
+ it { expect(@playlist.playlist_items.first).to be_a Yt::PlaylistItem }
18
18
  end
19
19
 
20
20
  describe '#add_video' do
@@ -36,7 +36,7 @@ describe Yt::Associations::PlaylistItems, scenario: :device_app do
36
36
  let(:video_id) { 'MESycYJytkU' }
37
37
  before { @playlist.add_video video_id }
38
38
 
39
- it { expect(@playlist.delete_playlist_items).to eq [true] }
40
- it { expect{@playlist.delete_playlist_items}.to change{@playlist.playlist_items.count}.by(-1) }
39
+ it { expect(@playlist.delete_playlist_items.compact).to eq [true] }
40
+ it { expect{@playlist.delete_playlist_items}.to change{@playlist.playlist_items.count} }
41
41
  end
42
42
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Claudio Baccigalupo