tweetomator 1.0.1 → 1.0.2
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 +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +5 -1
- data/lib/tweetomator/version.rb +1 -1
- data/test/lib/finders/tweet_finder_test.rb +4 -10
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4fcc324183e143e5b0cdc10f46ce302813f6c887
|
4
|
+
data.tar.gz: 6be15674f917def226b68a7333af27b65806e87f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 92db45f499d31361254fda74f3a3f37ac31fc4ffa5586a47e618e6f0d3f234cd11ea56780a97a8e9cc7a2d3729bc4a72e0dd9bb842df1bd8b2f534389236d747
|
7
|
+
data.tar.gz: 4db5bc27fb25590e749a98de830d1c4760d6f9b3f1b09b100228325e2b3ad56d460a3a67f5de47060f4b0d3f631967d54e68d8cd006b2b4ec12a1f8b0d6aaecc
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -57,14 +57,18 @@ Create a new Tweetomator
|
|
57
57
|
e.g.
|
58
58
|
|
59
59
|
twitter_config = TwitterConfig.new([...])
|
60
|
+
|
60
61
|
flickr_config = FlickrConfig.new([...])
|
62
|
+
|
61
63
|
tweetomator_config = TweetomatorConfig.new(twitter, flickr, [...])
|
64
|
+
|
62
65
|
tweetomator = Tweetomator.new(tweetomator_config)
|
66
|
+
|
63
67
|
tweetomator.run
|
64
68
|
|
65
69
|
## Contributing
|
66
70
|
|
67
|
-
1. Fork it ( https://github.com/
|
71
|
+
1. Fork it ( https://github.com/natyoung/tweetomator/fork )
|
68
72
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
69
73
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
70
74
|
4. Push to the branch (`git push origin my-new-feature`)
|
data/lib/tweetomator/version.rb
CHANGED
@@ -3,17 +3,11 @@ require_relative '../../../lib/finders/tweet_finder'
|
|
3
3
|
|
4
4
|
class TestTweetFinder < Minitest::Unit::TestCase
|
5
5
|
def setup
|
6
|
-
|
7
|
-
result_1 = 'I just backed Potato Salad on @Kickstarter kck.st/1pLytCe'
|
8
|
-
result_2 = 'I am a chicken'
|
9
|
-
result_3 = 'And there I was in Sri Lanka, formerly Ceylon'
|
10
|
-
mock_search_result.expect :text, result_1
|
11
|
-
mock_search_result.expect :text, result_2
|
12
|
-
mock_search_result.expect :text, result_3
|
6
|
+
search_result = 'I just backed Potato Salad on @Kickstarter kck.st/1pLytCe'
|
13
7
|
mock_client = Minitest::Mock.new
|
14
|
-
3.times { mock_client.expect :search,
|
15
|
-
stop_words =
|
16
|
-
@finder = TweetFinder.new(mock_client,
|
8
|
+
3.times { mock_client.expect :search, search_result, [String] }
|
9
|
+
stop_words = search_result.split
|
10
|
+
@finder = TweetFinder.new(mock_client, ['Trumpets', 'Bookmarks', 'Potato Salads'], stop_words)
|
17
11
|
end
|
18
12
|
|
19
13
|
def test_that_it_finds_a_tweet_per_query
|