mechanize_content 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (32) hide show
  1. data/.gitignore +4 -0
  2. data/Gemfile +4 -0
  3. data/LICENSE +20 -0
  4. data/README.rdoc +42 -0
  5. data/Rakefile +2 -0
  6. data/lib/mechanize_content/util.rb +35 -0
  7. data/lib/mechanize_content/version.rb +3 -0
  8. data/lib/mechanize_content.rb +189 -0
  9. data/mechanize_content.gemspec +25 -0
  10. data/spec/fixtures/a-fistful-of-red-dead-redemption-ps3-for-a-few-dollars-less-on.html +754 -0
  11. data/spec/fixtures/another-world-15th-anniversary-edition-now-on-gog-com.html +2416 -0
  12. data/spec/fixtures/another_world_15th_anniversary_edition.html +805 -0
  13. data/spec/fixtures/cmp.html +333 -0
  14. data/spec/fixtures/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april.html +1593 -0
  15. data/spec/fixtures/gdc_2010_rounds_off_indie_cove.html +698 -0
  16. data/spec/fixtures/google.html +42 -0
  17. data/spec/fixtures/gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3.html +1012 -0
  18. data/spec/fixtures/johnny.jpg +0 -0
  19. data/spec/fixtures/joystiq-xbox-usb-support-580.jpg +0 -0
  20. data/spec/fixtures/mutiny.html +264 -0
  21. data/spec/fixtures/nuff-said-good-old-games-gets-another-world-168150.html +5492 -0
  22. data/spec/fixtures/rock-band-3-out-this-holiday-will-revolutionize-genre.html +1157 -0
  23. data/spec/fixtures/rockband_facebook.html +93 -0
  24. data/spec/fixtures/spartan.html +391 -0
  25. data/spec/fixtures/techmeme.html +2216 -0
  26. data/spec/fixtures/time-warner-retail-egm.html +49 -0
  27. data/spec/fixtures/witcher.html +458 -0
  28. data/spec/fixtures/xbox-360-gaining-usb-storage-support-in-2010-update.html +2462 -0
  29. data/spec/mechanize-content_spec.rb +195 -0
  30. data/spec/spec.opts +1 -0
  31. data/spec/spec_helper.rb +11 -0
  32. metadata +182 -0
@@ -0,0 +1,195 @@
1
+ # -*- encoding: utf-8 -*-
2
+ require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
3
+
4
+ describe "MechanizeContent" do
5
+
6
+ def register(url, fixture)
7
+ FakeWeb.register_uri(:any, url, :response => File.join(File.dirname(__FILE__), 'fixtures', fixture))
8
+ end
9
+
10
+ def register_image(url, fixture)
11
+ FakeWeb.register_uri(:any, url, :body => File.join(File.dirname(__FILE__), 'fixtures', fixture))
12
+ end
13
+
14
+ before(:all) do
15
+ register("http://techmeme.com/",'techmeme.html')
16
+ register("http://www.gog.com/en/gamecard/another_world_15th_anniversary_edition",'another_world_15th_anniversary_edition.html')
17
+ register("http://www.destructoid.com/-nuff-said-good-old-games-gets-another-world-168150.phtml",'nuff-said-good-old-games-gets-another-world-168150.html')
18
+ register("http://www.rockstargames.com/newswire/2010/03/18/4061/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april",'episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april.html')
19
+ register("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601",'cmp.html')
20
+ register("http://www.gamesetwatch.com/2010/03/gdc_2010_rounds_off_indie_cove.php",'gdc_2010_rounds_off_indie_cove.html')
21
+ register("http://www.mutinydesign.co.uk/scripts/html-base-tag---1/",'mutiny.html')
22
+ register("http://www.joystiq.com/2010/03/18/xbox-360-gaining-usb-storage-support-in-2010-update/",'xbox-360-gaining-usb-storage-support-in-2010-update.html')
23
+ register("http://www.vg247.com/2010/03/18/gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3/",'gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3.html')
24
+ register("http://www.facebook.com/RockBand",'rockband_facebook.html')
25
+ register("http://www.vg247.com/2010/03/09/rock-band-3-out-this-holiday-will-revolutionize-genre/",'rock-band-3-out-this-holiday-will-revolutionize-genre.html')
26
+ register("http://www.joystiq.com/2010/03/18/another-world-15th-anniversary-edition-now-on-gog-com/",'another-world-15th-anniversary-edition-now-on-gog-com.html')
27
+ register("http://www.godofwar.com/spartansstandtall/",'spartan.html')
28
+ register("http://www.thewitcher.com/",'witcher.html')
29
+ register("http://www.egmnow.com/press/time-warner-retail-egm.html",'time-warner-retail-egm.html')
30
+ register("http://www.joystiq.com/2010/07/23/a-fistful-of-red-dead-redemption-ps3-for-a-few-dollars-less-on/",'a-fistful-of-red-dead-redemption-ps3-for-a-few-dollars-less-on.html')
31
+
32
+ register_image("http://www.rockstargames.com/rockstar/local_data/US/img/news/eflc_luisjohnny.jpg",'johnny.jpg')
33
+ register_image("http://www.blogcdn.com/www.joystiq.com/media/2010/03/joystiq-xbox-usb-support-580.jpg",'joystiq-xbox-usb-support-580.jpg')
34
+ end
35
+
36
+ it "initialise mechanize content" do
37
+ mc = MechanizeContent::Parser.new("http://www.google.com")
38
+ mc.urls.first.should eql("http://www.google.com")
39
+ end
40
+
41
+ it "fetch the best title" do
42
+ mc = MechanizeContent::Parser.new("http://techmeme.com/")
43
+ mc.best_title.should eql("Techmeme")
44
+ end
45
+
46
+ it "page has incorrect class so only url returned" do
47
+ mc = MechanizeContent::Parser.new("http://techmeme.com/")
48
+ agent = mock("agent")
49
+ page = mock("page")
50
+ page.stub!(:class).and_return(String)
51
+ agent.should_receive(:get).with("http://techmeme.com/").and_return(page)
52
+ mc.should_receive(:init_agent).and_return(agent)
53
+ mc.best_title.should eql("http://techmeme.com/")
54
+ end
55
+
56
+ it "page has no title so only url returned" do
57
+ mc = MechanizeContent::Parser.new("http://techmeme.com/")
58
+ agent = mock("agent")
59
+ page = mock("page")
60
+ page.stub!(:class).and_return(Mechanize::Page)
61
+ page.stub!(:title).and_return(nil)
62
+ agent.should_receive(:get).with("http://techmeme.com/").and_return(page)
63
+ mc.should_receive(:init_agent).and_return(agent)
64
+ mc.best_title.should eql("http://techmeme.com/")
65
+ end
66
+
67
+ it "page retrival errors" do
68
+ mc = MechanizeContent::Parser.new("http://techmeme.com/")
69
+ agent = mock("agent")
70
+ page = mock("page")
71
+ page.stub!(:class).and_return(Mechanize::Page)
72
+ agent.should_receive(:get).with("http://techmeme.com/").and_raise(Timeout::Error)
73
+ agent.should_receive(:get).with("http://somewherelse.com/").and_raise(Errno::ECONNRESET)
74
+ mc.should_receive(:init_agent).any_number_of_times.and_return(agent)
75
+
76
+ mc.fetch_page("http://techmeme.com/").should eql(nil)
77
+ mc.fetch_page("http://somewherelse.com/").should eql(nil)
78
+ end
79
+
80
+ it "mechanize page issues" do
81
+ mc = MechanizeContent::Parser.new("http://techmeme.com/")
82
+ agent = mock("agent")
83
+ page = mock("page")
84
+ mc.stub!(:init_agent).and_return(agent)
85
+ page.stub!(:code).and_return(400)
86
+ agent.should_receive(:get).with("http://techmeme.com/").and_return(page)
87
+ mc.fetch_page("http://techmeme.com/").should eql(nil)
88
+ end
89
+
90
+ it "fetch some text" do
91
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
92
+ page = mc.fetch_page("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
93
+ mc.fetch_text(page).should eql(nil)
94
+
95
+ mc2 = MechanizeContent::Parser.new("http://www.gamesetwatch.com/2010/03/gdc_2010_rounds_off_indie_cove.php")
96
+ page = mc2.fetch_page("http://www.gamesetwatch.com/2010/03/gdc_2010_rounds_off_indie_cove.php")
97
+ mc2.fetch_text(page).should eql("Game Developers Conference organizers have confirmed the final set of independent game-specific content, including Ron Carmel on the just-debuted Indie Fund, the Gamma IV party/showcase, and the EGW-replacing Nuovo Sessions game showcase.The newly confirmed details round off a multitude of independent game-specific content at the March 9th-13th event, held at the Moscone Center in San Francisco, including the 12th Annual Independent Games Festival -- featuring over 30 top indie games playable on the GDC Expo floor from Thursday 11th to Saturday 13th, as well as the major IGF Awards on Thursday 11th at 6.30pm.In addition, the 4th Independent Games Summit on Tuesday 9th and Wednesday 10th has added and clarified a number of sessions, with 2D Boy's Ron Carmel kicking off the event with 'Indies and Publishers: Fixing a System That Never Worked', now confirmed to discuss the new Indie Fund organization.Another major new panel, 'Tripping The Art Fantastic', features Spelunky creator Derek Yu, Braid artist David Hellman and Super Meat Boy co-creator Edmund McMillen discussing \"how each one of these figures influences the state of game art, from hand painted epics to short form experimental Flash games.\"")
98
+ end
99
+
100
+ it "find the best text" do
101
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
102
+ mc.best_text.should eql(nil)
103
+
104
+ mc2 = MechanizeContent::Parser.new("http://www.gamesetwatch.com/2010/03/gdc_2010_rounds_off_indie_cove.php")
105
+ mc2.best_text.should eql("Game Developers Conference organizers have confirmed the final set of independent game-specific content, including Ron Carmel on the just-debuted Indie Fund, the Gamma IV party/showcase, and the EGW-replacing Nuovo Sessions game showcase.The newly confirmed details round off a multitude of independent game-specific content at the March 9th-13th event, held at the Moscone Center in San Francisco, including the 12th Annual Independent Games Festival -- featuring over 30 top indie games playable on the GDC Expo floor from Thursday 11th to Saturday 13th, as well as the major IGF Awards on Thursday 11th at 6.30pm.In addition, the 4th Independent Games Summit on Tuesday 9th and Wednesday 10th has added and clarified a number of sessions, with 2D Boy's Ron Carmel kicking off the event with 'Indies and Publishers: Fixing a System That Never Worked', now confirmed to discuss the new Indie Fund organization.Another major new panel, 'Tripping The Art Fantastic', features Spelunky creator Derek Yu, Braid artist David Hellman and Super Meat Boy co-creator Edmund McMillen discussing \"how each one of these figures influences the state of game art, from hand painted epics to short form experimental Flash games.\"")
106
+ end
107
+
108
+ it "reject all gifs" do
109
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
110
+ MechanizeContent::Util.valid_image?(500, 500, "http://www.cmpevents.com/GD10/ablank.gif2").should eql(false)
111
+ end
112
+
113
+ it "reject image with banner in the name" do
114
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
115
+ MechanizeContent::Util.valid_image?(500, 500, "http://www.cmpevents.com/GD10/banner.png").should eql(false)
116
+ end
117
+
118
+ it "reject image that is too small" do
119
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
120
+ MechanizeContent::Util.valid_image?(64, 500, "http://www.cmpevents.com/GD10/toosmall.png").should eql(false)
121
+ end
122
+
123
+ it "allow good images" do
124
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
125
+ MechanizeContent::Util.valid_image?(500, 500, "http://www.cmpevents.com/GD10/perfecto.png").should eql(true)
126
+ end
127
+
128
+ it "build a base url for images" do
129
+ mc = MechanizeContent::Parser.new("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
130
+ page = mc.fetch_page("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
131
+ MechanizeContent::Util.get_base_url(page.parser, page.uri).to_s.should eql("https://www.cmpevents.com/GD10/a.asp?option=C&V=11&SessID=10601")
132
+
133
+ mc = MechanizeContent::Parser.new("http://www.mutinydesign.co.uk/scripts/html-base-tag---1/")
134
+ page = mc.fetch_page("http://www.mutinydesign.co.uk/scripts/html-base-tag---1/")
135
+ MechanizeContent::Util.get_base_url(page.parser, page.uri).to_s.should eql("http://www.mutinydesign.co.uk/")
136
+ end
137
+
138
+ it "find image" do
139
+ mc = MechanizeContent::Parser.new("http://www.rockstargames.com/newswire/2010/03/18/4061/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april")
140
+ page = mc.fetch_page("http://www.rockstargames.com/newswire/2010/03/18/4061/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april")
141
+ mc.fetch_image(page).should eql("http://www.rockstargames.com/rockstar/local_data/US/img/news/eflc_luisjohnny.jpg")
142
+
143
+ mc3 = MechanizeContent::Parser.new("http://www.gog.com/en/gamecard/another_world_15th_anniversary_edition")
144
+ page3 = mc3.fetch_page("http://www.gog.com/en/gamecard/another_world_15th_anniversary_edition")
145
+ mc3.fetch_image(page3).should eql(nil)
146
+
147
+ mc4 = MechanizeContent::Parser.new("http://www.gog.com/page_has_no_content")
148
+ page4 = mock("page")
149
+ mc4.stub!(:fetch_content).with(page4).and_return(nil)
150
+ mc4.fetch_image(page4).should eql(nil)
151
+
152
+ mc5 = MechanizeContent::Parser.new("http://www.egmnow.com/press/time-warner-retail-egm.html")
153
+ page5 = mc5.fetch_page("http://www.egmnow.com/press/time-warner-retail-egm.html")
154
+ mc5.fetch_image(page5).should eql("http://www.egmnow.com/images/egmlogo.jpg")
155
+ end
156
+
157
+ it "find the best image" do
158
+ mc = MechanizeContent::Parser.new("http://www.rockstargames.com/newswire/2010/03/18/4061/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april")
159
+ mc.best_image.should eql("http://www.rockstargames.com/rockstar/local_data/US/img/news/eflc_luisjohnny.jpg")
160
+
161
+ mc3 = MechanizeContent::Parser.new("http://www.gog.com/en/gamecard/another_world_15th_anniversary_edition")
162
+ mc3.best_image.should eql(nil)
163
+ end
164
+
165
+ it "find the best content from multiple urls" do
166
+ mc = MechanizeContent::Parser.new("http://www.rockstargames.com/newswire/2010/03/18/4061/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april", "http://www.vg247.com/2010/03/18/gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3/")
167
+ mc.best_title.should eql("Rockstar Games | Rockstar News Wire | Episodes from Liberty City Now Coming to PlayStation 3 and PC this April")
168
+ mc.best_text.should eql("Due to a last minute game submission request from Sony Computer Entertainment Europe to edit some of the in-game Liberty City radio station, television, and internet content – we are forced to delay the worldwide release of Grand Theft Auto: Episodes from Liberty City for both PlayStation 3 and PC for an extra two weeks.\rThe new release date for Episodes from Liberty City - and the two downloadable episodes The Lost and Damned and The Ballad of Gay Tony - on those platforms is now April 13th in North America and April 16th in Europe.  This new date will enable us to rectify these changes for Sony Europe, and still allow for a level playing field for all of the Grand Theft Auto fans that have been waiting patiently for this release.  In the meantime, we’re moving full speed ahead towards the new game release date.  On that note – please be aware that the Grand Theft Auto IV PlayStation 3 leaderboards at Rockstar Games Social Club will be down for maintenance for one week starting March 22nd as we work on their re-launch in support of Episodes from Liberty City.\rBelow are answers to some additional questions that we know some of you may have…\rThose game changes sound pretty minor.  Why does the game have to be delayed a whole two weeks?\rUnfortunately, with each round of changes comes fully re-testing the game and a full re-submission to PlayStation.  This is the nature of the game submission process.  Believe us, if we could expedite the turnaround any sooner – we would.  We are dying to get this game in the hands of fans who’ve waited for it for so long in the first place.Why is content being edited just for the European release?  This doesn’t seem fair.\rThere are different regional requirements for content – whether dictated by ratings boards like the ESRB and BBFC or by SCEE – this is pretty standard in the world of entertainment.\rIf this content is only being edited for the PlayStation 3 release, and only in Europe… why does everyone in North America etc have to wait?  And why do PC players have to wait at all?\rThis was a tough decision but with a simultaneous release, everyone can experience multiplayer simultaneously, take part in online events together, be on level ground on leaderboards, etc. What about those Episodes from Liberty City PSN and GFWL Social Club multiplayer events you announced for April 2nd and 3rd?  \rThe first Episodes events for those systems will now be on April 16th and 17th.  We will most likely replace the originally scheduled early April events with one for another game.  Any requests?\rAny other questions, please feel to leave in the Comments area and we’ll do our best to answer.  While this sort of thing may be commonplace in the world of interactive entertainment, we know that game delays are as disappointing to you all as they are to us – and we thank all of our fans immensely for their patience and understanding.\rRockstar Games")
169
+ mc.best_image.should eql("http://www.rockstargames.com/rockstar/local_data/US/img/news/eflc_luisjohnny.jpg")
170
+
171
+ mc = MechanizeContent::Parser.new("http://www.facebook.com/RockBand", "http://www.vg247.com/2010/03/09/rock-band-3-out-this-holiday-will-revolutionize-genre/")
172
+ mc.best_title.should eql("Rock Band | Facebook")
173
+ mc.best_text.should eql("Harmonix just confirmed that Rock Band 3 will release this holiday season.Said the firm on Rock Band’s Facebook page:“Harmonix is developing Rock Band 3 for worldwide release this holiday season! The game, which will be published by MTV Games and distributed by Electronic Arts, will innovate and revolutionize the music genre once again, just as Harmonix did with the original Rock Band, Rock Band 2 and The Beatles: Rock Band. Stay tuned for more details!”There’s no more detail right now, but keep watching for updates from GDC.")
174
+ mc.best_image.should eql("http://assets.vg247.com/current//2010/03/rockbandlogo.jpg")
175
+ end
176
+
177
+ it "gog link no text" do
178
+ mc = MechanizeContent::Parser.new("http://www.gog.com/en/gamecard/another_world_15th_anniversary_edition", "http://www.destructoid.com/-nuff-said-good-old-games-gets-another-world-168150.phtml", "http://www.joystiq.com/2010/03/18/another-world-15th-anniversary-edition-now-on-gog-com/")
179
+ mc.best_title.should eql("Another World: 15th Anniversary Edition - GOG.com")
180
+ mc.best_text.should eql("Another World -- or Out of this World, as many of you will know it by -- is now on DRM-free digital distribution service Good Old Games. It can be had for $9.99. Need I say more?\rI love the game, even though I have never made it more than oh, five minutes in. It's more or less universally loved by the Destructoid staff. Not long after we got an email detailing the good news, the thread soon reached fifteen or so replies full of praise for the game.\rOther, less exciting recent releases include: Empire Earth II Gold, Gabriel Knight 3, and Aquanox. Not to completely s**t on these games, but this is Another World we're talking about here.")
181
+ end
182
+
183
+ it "getting wrong blurb from detructoid" do
184
+ mc = MechanizeContent::Parser.new("http://www.destructoid.com/-nuff-said-good-old-games-gets-another-world-168150.phtml")
185
+ mc.best_title.should eql("'Nuff said: Good Old Games gets Another World- Destructoid")
186
+ mc.best_text.should eql("Another World -- or Out of this World, as many of you will know it by -- is now on DRM-free digital distribution service Good Old Games. It can be had for $9.99. Need I say more?\rI love the game, even though I have never made it more than oh, five minutes in. It's more or less universally loved by the Destructoid staff. Not long after we got an email detailing the good news, the thread soon reached fifteen or so replies full of praise for the game.\rOther, less exciting recent releases include: Empire Earth II Gold, Gabriel Knight 3, and Aquanox. Not to completely s**t on these games, but this is Another World we're talking about here.")
187
+ mc.best_image.should eql(nil)
188
+ end
189
+
190
+ it "get this flash site to return nil for a title" do
191
+ mc = MechanizeContent::Parser.new("http://www.thewitcher.com/")
192
+ mc.best_text.should eql(nil)
193
+ end
194
+
195
+ end
data/spec/spec.opts ADDED
@@ -0,0 +1 @@
1
+ --color
@@ -0,0 +1,11 @@
1
+ $LOAD_PATH.unshift(File.dirname(__FILE__))
2
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
3
+ require 'mechanize_content'
4
+ require 'spec'
5
+ require 'spec/autorun'
6
+ require "fakeweb"
7
+ FakeWeb.allow_net_connect = false
8
+
9
+ Spec::Runner.configure do |config|
10
+
11
+ end
metadata ADDED
@@ -0,0 +1,182 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mechanize_content
3
+ version: !ruby/object:Gem::Version
4
+ hash: 23
5
+ prerelease:
6
+ segments:
7
+ - 0
8
+ - 2
9
+ - 0
10
+ version: 0.2.0
11
+ platform: ruby
12
+ authors:
13
+ - John Griffin
14
+ autorequire:
15
+ bindir: bin
16
+ cert_chain: []
17
+
18
+ date: 2011-02-26 00:00:00 +00:00
19
+ default_executable:
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
22
+ name: mechanize
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ hash: 23
30
+ segments:
31
+ - 1
32
+ - 0
33
+ - 0
34
+ version: 1.0.0
35
+ type: :runtime
36
+ version_requirements: *id001
37
+ - !ruby/object:Gem::Dependency
38
+ name: imagesize
39
+ prerelease: false
40
+ requirement: &id002 !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ~>
44
+ - !ruby/object:Gem::Version
45
+ hash: 25
46
+ segments:
47
+ - 0
48
+ - 1
49
+ - 1
50
+ version: 0.1.1
51
+ type: :runtime
52
+ version_requirements: *id002
53
+ - !ruby/object:Gem::Dependency
54
+ name: rspec
55
+ prerelease: false
56
+ requirement: &id003 !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ hash: 25
62
+ segments:
63
+ - 1
64
+ - 3
65
+ - 1
66
+ version: 1.3.1
67
+ type: :development
68
+ version_requirements: *id003
69
+ - !ruby/object:Gem::Dependency
70
+ name: fakeweb
71
+ prerelease: false
72
+ requirement: &id004 !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - "="
76
+ - !ruby/object:Gem::Version
77
+ hash: 21
78
+ segments:
79
+ - 1
80
+ - 2
81
+ - 5
82
+ version: 1.2.5
83
+ type: :development
84
+ version_requirements: *id004
85
+ description: pass in a url or urls and mechanize-content will select the best block of text, image and title by analysing the page content
86
+ email:
87
+ - johnog@gmail.com
88
+ executables: []
89
+
90
+ extensions: []
91
+
92
+ extra_rdoc_files: []
93
+
94
+ files:
95
+ - .gitignore
96
+ - Gemfile
97
+ - LICENSE
98
+ - README.rdoc
99
+ - Rakefile
100
+ - lib/mechanize_content.rb
101
+ - lib/mechanize_content/util.rb
102
+ - lib/mechanize_content/version.rb
103
+ - mechanize_content.gemspec
104
+ - spec/fixtures/a-fistful-of-red-dead-redemption-ps3-for-a-few-dollars-less-on.html
105
+ - spec/fixtures/another-world-15th-anniversary-edition-now-on-gog-com.html
106
+ - spec/fixtures/another_world_15th_anniversary_edition.html
107
+ - spec/fixtures/cmp.html
108
+ - spec/fixtures/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april.html
109
+ - spec/fixtures/gdc_2010_rounds_off_indie_cove.html
110
+ - spec/fixtures/google.html
111
+ - spec/fixtures/gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3.html
112
+ - spec/fixtures/johnny.jpg
113
+ - spec/fixtures/joystiq-xbox-usb-support-580.jpg
114
+ - spec/fixtures/mutiny.html
115
+ - spec/fixtures/nuff-said-good-old-games-gets-another-world-168150.html
116
+ - spec/fixtures/rock-band-3-out-this-holiday-will-revolutionize-genre.html
117
+ - spec/fixtures/rockband_facebook.html
118
+ - spec/fixtures/spartan.html
119
+ - spec/fixtures/techmeme.html
120
+ - spec/fixtures/time-warner-retail-egm.html
121
+ - spec/fixtures/witcher.html
122
+ - spec/fixtures/xbox-360-gaining-usb-storage-support-in-2010-update.html
123
+ - spec/mechanize-content_spec.rb
124
+ - spec/spec.opts
125
+ - spec/spec_helper.rb
126
+ has_rdoc: true
127
+ homepage: http://github.com/john-griffin/mechanize-content
128
+ licenses: []
129
+
130
+ post_install_message:
131
+ rdoc_options: []
132
+
133
+ require_paths:
134
+ - lib
135
+ required_ruby_version: !ruby/object:Gem::Requirement
136
+ none: false
137
+ requirements:
138
+ - - ">="
139
+ - !ruby/object:Gem::Version
140
+ hash: 3
141
+ segments:
142
+ - 0
143
+ version: "0"
144
+ required_rubygems_version: !ruby/object:Gem::Requirement
145
+ none: false
146
+ requirements:
147
+ - - ">="
148
+ - !ruby/object:Gem::Version
149
+ hash: 3
150
+ segments:
151
+ - 0
152
+ version: "0"
153
+ requirements: []
154
+
155
+ rubyforge_project: mechanize_content
156
+ rubygems_version: 1.5.2
157
+ signing_key:
158
+ specification_version: 3
159
+ summary: scrape the best content from a page
160
+ test_files:
161
+ - spec/fixtures/a-fistful-of-red-dead-redemption-ps3-for-a-few-dollars-less-on.html
162
+ - spec/fixtures/another-world-15th-anniversary-edition-now-on-gog-com.html
163
+ - spec/fixtures/another_world_15th_anniversary_edition.html
164
+ - spec/fixtures/cmp.html
165
+ - spec/fixtures/episodes_from_liberty_city_now_coming_to_playstation_3_and_pc_this_april.html
166
+ - spec/fixtures/gdc_2010_rounds_off_indie_cove.html
167
+ - spec/fixtures/google.html
168
+ - spec/fixtures/gta-iv-episodes-from-liberty-city-sees-slight-delay-on-pc-and-ps3.html
169
+ - spec/fixtures/johnny.jpg
170
+ - spec/fixtures/joystiq-xbox-usb-support-580.jpg
171
+ - spec/fixtures/mutiny.html
172
+ - spec/fixtures/nuff-said-good-old-games-gets-another-world-168150.html
173
+ - spec/fixtures/rock-band-3-out-this-holiday-will-revolutionize-genre.html
174
+ - spec/fixtures/rockband_facebook.html
175
+ - spec/fixtures/spartan.html
176
+ - spec/fixtures/techmeme.html
177
+ - spec/fixtures/time-warner-retail-egm.html
178
+ - spec/fixtures/witcher.html
179
+ - spec/fixtures/xbox-360-gaining-usb-storage-support-in-2010-update.html
180
+ - spec/mechanize-content_spec.rb
181
+ - spec/spec.opts
182
+ - spec/spec_helper.rb