rrimm 0.12.0 → 0.12.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,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NjM4NjM5NDhhMzZiYzc4MjlmZDZmNzE3MzJiZTliODcyYzZkY2VlMA==
4
+ ODgwNzU2ZTBmNTM2OTM0NDAwYTc1MmMzMjY3OGQ3NTMwZmFhNjg4Yw==
5
5
  data.tar.gz: !binary |-
6
- NzUyMzkwYWU5ZGIyZDE4YzMzN2FkMDE4ZWI3YWRlOGQ2MzAyMzg1Zg==
6
+ NzkzYmRlMDQyZWQxZGY1OWI0MTIwNzk2MmExZmFiMmM5OGUxNTFiYw==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- Y2YxODJmODFmMzE2YTdkN2M5ZDhhMWI4YTE1YzAxZWU1NGZkODM0NDBmMmM4
10
- YzM0YjY4MWRlYzViMTBjNTM4YWUxM2I2ODJiYzdjOWQzYjRmZGM1OGI4MGE3
11
- OWUzYWE3YmYwODg5MjdiMTk3NDY5MDI0N2I1ZGViNGYzOTlhZDg=
9
+ NGRiYzgyNDVhNjY1NDhhNWY4ZGE3ODkzYTY2MDIwZGI4MmM0NzBjNjczYWZm
10
+ MTRjZGJmNTY5ZjcyYzhiMTdhNTZjZWIzMTZkMDJkMGU4M2ExYTgyNjdkYTlh
11
+ OWUyNmEwYmRlZTI1MGE0MDBiMzkzZWYzMzZiMTBiMWVjY2FmMDc=
12
12
  data.tar.gz: !binary |-
13
- MWQ0MWU5NGQ0ZjM5ZTg1MWFiOGI1NTA1NTZhNDcwMTE5OWYyNmRiZDNmNDk5
14
- MzYwYjEyNmNjOGI1Y2YyOWJlY2Y5ZGI4YjI3YjQ0YjUzN2JiMjlkNzI1MGE2
15
- NGY0ZDRhOTM3NGNiZjkyZjE4Nzk5MWM5OTBmMWUxMjUzNTUwMzc=
13
+ NDdhMjM1MmI5ZjE4OTcwM2RlMDEyZGE5NjhkZTY3MTc5NWE1YTJhOTY2NTNi
14
+ YWIxODY5YTM5YzUwODMyNDkxNGRhZDM3MmU1ZTQyNDUxNTgzMjhhNjY3NzRj
15
+ YTFiNjVhZGE3Y2NmN2M4YWQ2NjFiNTk3YjRmZWM5OGRiNzE2OGI=
@@ -10,6 +10,7 @@ module RRImm
10
10
  else
11
11
  raise NoMethodError
12
12
  end
13
+ self
13
14
  end
14
15
 
15
16
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'rrimm'
3
- s.version = '0.12.0'
3
+ s.version = '0.12.1'
4
4
  s.licenses = ['Apache Licence v2']
5
5
  s.summary = "RSS to email tool"
6
6
  s.description = "imm reboot in ruby. Retrieve rss feeds and send them by email"
@@ -31,6 +31,13 @@ describe RRImm::FeedConfig do
31
31
  f.massages << {select: Proc.new { |el| el % 2 == 0 }}
32
32
  expect(f.massage(feed)).to eq([2,4])
33
33
  end
34
+ it 'applies 2 massages in a row' do
35
+ feed = (1..10)
36
+ f = RRImm::FeedConfig.new 'a random feed'
37
+ f.massages << {select: Proc.new { |el| el % 2 == 0 }}
38
+ f.massages << {select: Proc.new { |el| el % 4 == 0 }}
39
+ expect(f.massage(feed)).to eq([4,8])
40
+ end
34
41
  end
35
42
 
36
43
  describe ".format" do
@@ -53,5 +60,10 @@ describe RRImm::FeedConfigExtensions do
53
60
  f.select { |el| el % 2 == 0 }
54
61
  expect(f.massage(feed)).to eq([2,4])
55
62
  end
63
+ it 'returns the feed config to allow chaining' do
64
+ feed = (1..5)
65
+ f = RRImm::FeedConfig.new 'a random feed'
66
+ expect(f.select { |el| el % 2 == 0 }).to be_a(RRImm::FeedConfig)
67
+ end
56
68
  end
57
69
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rrimm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.0
4
+ version: 0.12.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Grégoire Seux
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-13 00:00:00.000000000 Z
11
+ date: 2015-08-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: open_uri_redirections