market_bot 0.8.1 → 0.8.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -15,14 +15,14 @@ def stub_hydra(hydra)
15
15
  (0...4).each do |i|
16
16
  start = i * 24
17
17
  response = Typhoeus::Response.new(:code => 200, :headers => '', :body => test_src_pages[i + 1])
18
- url = "https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=#{start}&num=24"
18
+ url = "https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=#{start}&num=24&hl=en"
19
19
  hydra.stub(:get, url).and_return(response)
20
20
  end
21
21
 
22
22
  test_src_editors_choice = read_file(File.dirname(__FILE__), 'data', "leaderboard-apps_editors_choice.txt")
23
23
 
24
24
  response = Typhoeus::Response.new(:code => 200, :headers => '', :body => test_src_editors_choice)
25
- url = "https://play.google.com/store/apps/collection/editors_choice"
25
+ url = "https://play.google.com/store/apps/collection/editors_choice?hl=en"
26
26
  hydra.stub(:get, url).and_return(response)
27
27
  end
28
28
 
@@ -39,12 +39,12 @@ def check_results(results)
39
39
  end
40
40
 
41
41
  it 'should have the top ranking app with valid details' do
42
- results.first[:developer].should == 'Disney'
43
- results.first[:market_id].should == 'com.disney.WMP'
44
- results.first[:market_url].should == 'https://play.google.com/store/apps/details?id=com.disney.WMP'
45
- results.first[:price_usd].should == '$0.99'
46
- results.first[:stars].should == '4.5'
47
- results.first[:title].should == "Where's My Perry?"
42
+ results.first[:developer].should == 'LevelUp Studio'
43
+ results.first[:market_id].should == 'com.levelup.beautifulwidgets'
44
+ results.first[:market_url].should == 'https://play.google.com/store/apps/details?id=com.levelup.beautifulwidgets&hl=en'
45
+ results.first[:price_usd].should == '$2.79'
46
+ results.first[:stars].should == '4.4'
47
+ results.first[:title].should == "Beautiful Widgets"
48
48
  end
49
49
 
50
50
  end
@@ -74,9 +74,9 @@ describe 'Leaderboard' do
74
74
  lb = Leaderboard.new(test_id, test_category)
75
75
  urls = lb.market_urls(:min_page => 1, :max_page => 3)
76
76
  urls.should == [
77
- 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=0&num=24',
78
- 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=24&num=24',
79
- 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=48&num=24'
77
+ 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=0&num=24&hl=en',
78
+ 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=24&num=24&hl=en',
79
+ 'https://play.google.com/store/apps/category/ARCADE/collection/topselling_paid?start=48&num=24&hl=en'
80
80
  ]
81
81
  end
82
82
 
@@ -123,7 +123,7 @@ describe 'Leaderboard' do
123
123
  app[:price_usd].should == nil
124
124
  app[:developer].should == 'Vector Unit'
125
125
  app[:market_id].should == 'com.vectorunit.blue'
126
- app[:market_url].should == 'https://play.google.com/store/apps/details?id=com.vectorunit.blue'
126
+ app[:market_url].should == 'https://play.google.com/store/apps/details?id=com.vectorunit.blue&hl=en'
127
127
  end
128
128
  end
129
129
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: market_bot
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.8.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-07-22 00:00:00.000000000 Z
12
+ date: 2012-08-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: typhoeus
@@ -241,7 +241,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
241
241
  version: '0'
242
242
  segments:
243
243
  - 0
244
- hash: 3784964244319014321
244
+ hash: -1852717487623223623
245
245
  required_rubygems_version: !ruby/object:Gem::Requirement
246
246
  none: false
247
247
  requirements:
@@ -250,7 +250,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
250
250
  version: '0'
251
251
  requirements: []
252
252
  rubyforge_project:
253
- rubygems_version: 1.8.23
253
+ rubygems_version: 1.8.24
254
254
  signing_key:
255
255
  specification_version: 3
256
256
  summary: ! 'Market Bot: High performance Ruby scraper for Google''s Android Market'