Module: TokyoMetro::App::Renderer::Rss
- Defined in:
- lib/tokyo_metro/app/renderer/rss.rb
Constant Summary collapse
- LIST =
::YAML.load_file( "#{ ::TokyoMetro::DICTIONARY_DIR }/view/rss.yaml")
Class Method Summary collapse
Class Method Details
.test ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/tokyo_metro/app/renderer/rss.rb', line 5 def self.test feed_urls = LIST.values.map { | item | item[ "url" ] } feed_urls.each do | feed_url | feed = ::Feedjira::Feed.fetch_and_parse(feed_urls.first) p feed.title # => "PILOG" p feed.url # => "http://xoyip.hatenablog.com/" p feed.feed_url # => "http://xoyip.hatenablog.com/feed" p feed.etag # => "f6ce826cbbd07e222b6cee445fc981f730ad0693" p feed.last_modified # => 2014-01-15 11:47:34 UTC p feed.entries.count # => 7 p "" end end |