feedparser 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,32 @@
1
+ {
2
+ "version": "https://jsonfeed.org/version/1",
3
+ "title": "JSON Feed",
4
+ "description": "JSON Feed is a pragmatic syndication format for blogs, microblogs, and other time-based content.",
5
+ "home_page_url": "https://jsonfeed.org/",
6
+ "feed_url": "https://jsonfeed.org/feed.json",
7
+ "user_comment": "This feed allows you to read the posts from this site in any feed reader that supports the JSON Feed format. To add this feed to your reader, copy the following URL — https://jsonfeed.org/feed.json — and add it your reader.",
8
+ "favicon": "https://jsonfeed.org/graphics/icon.png",
9
+ "author": {
10
+ "name": "Brent Simmons and Manton Reece"
11
+ },
12
+ "items": [
13
+ {
14
+ "id": "https://jsonfeed.org/2017/05/17/announcing_json_feed",
15
+ "url": "https://jsonfeed.org/2017/05/17/announcing_json_feed",
16
+ "title": "Announcing JSON Feed",
17
+ "content_html": "<p>We — Manton Reece and Brent Simmons — have noticed that JSON has become the developers’ choice for APIs, and that developers will often go out of their way to avoid XML. JSON is simpler to read and write, and it’s less prone to bugs.</p>\n\n<p>So we developed JSON Feed, a format similar to <a href=\"http://cyber.harvard.edu/rss/rss.html\">RSS</a> and <a href=\"https://tools.ietf.org/html/rfc4287\">Atom</a> but in JSON. It reflects the lessons learned from our years of work reading and publishing feeds.</p>\n\n<p><a href=\"https://jsonfeed.org/version/1\">See the spec</a>. It’s at version 1, which may be the only version ever needed. If future versions are needed, version 1 feeds will still be valid feeds.</p>\n\n<h4>Notes</h4>\n\n<p>We have a <a href=\"https://github.com/manton/jsonfeed-wp\">WordPress plugin</a> and, coming soon, a JSON Feed Parser for Swift. As more code is written, by us and others, we’ll update the <a href=\"https://jsonfeed.org/code\">code</a> page.</p>\n\n<p>See <a href=\"https://jsonfeed.org/mappingrssandatom\">Mapping RSS and Atom to JSON Feed</a> for more on the similarities between the formats.</p>\n\n<p>This website — the Markdown files and supporting resources — <a href=\"https://github.com/brentsimmons/JSONFeed\">is up on GitHub</a>, and you’re welcome to comment there.</p>\n\n<p>This website is also a blog, and you can subscribe to the <a href=\"https://jsonfeed.org/xml/rss.xml\">RSS feed</a> or the <a href=\"https://jsonfeed.org/feed.json\">JSON feed</a> (if your reader supports it).</p>\n\n<p>We worked with a number of people on this over the course of several months. We list them, and thank them, at the bottom of the <a href=\"https://jsonfeed.org/version/1\">spec</a>. But — most importantly — <a href=\"http://furbo.org/\">Craig Hockenberry</a> spent a little time making it look pretty. :)</p>",
18
+ "date_published": "2017-05-17T08:02:12-07:00"
19
+ }
20
+ ]
21
+ }
22
+
23
+ ---
24
+
25
+ feed.format: json
26
+ feed.title: JSON Feed
27
+ feed.url: https://jsonfeed.org/
28
+ feed.summary: JSON Feed is a pragmatic syndication format for blogs, microblogs, and other time-based content.
29
+
30
+ feed.items[0].title: Announcing JSON Feed
31
+ feed.items[0].url: https://jsonfeed.org/2017/05/17/announcing_json_feed
32
+ feed.items[0].guid: https://jsonfeed.org/2017/05/17/announcing_json_feed
@@ -20,7 +20,8 @@ class TestAtomLive < MiniTest::Test
20
20
  feed = fetch_and_parse_feed( 'http://feeds.feedburner.com/railstutorial?format=xml' )
21
21
 
22
22
  assert_equal 'atom', feed.format
23
- assert_equal 'http://news.railstutorial.org/', feed.url
23
+ assert_equal 'http://news.learnenough.com/', feed.url
24
+ ## note was (2017/5): assert_equal 'http://news.railstutorial.org/', feed.url
24
25
  end
25
26
 
26
27
 
@@ -0,0 +1,23 @@
1
+ ###
2
+ # to run use
3
+ # ruby -I ./lib -I ./test test/test_json.rb
4
+ # or better
5
+ # rake test
6
+
7
+ require 'helper'
8
+
9
+
10
+ class TestJson < MiniTest::Test
11
+
12
+ def test_all
13
+ names = [
14
+ 'jsonfeed.json',
15
+ 'byparker.json',
16
+ ]
17
+
18
+ names.each do |name|
19
+ assert_feed_tests_for( name )
20
+ end
21
+ end
22
+
23
+ end # class TestJson
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: feedparser
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gerald Bauer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-17 00:00:00.000000000 Z
11
+ date: 2017-05-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logutils
@@ -58,14 +58,14 @@ dependencies:
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '3.13'
61
+ version: '3.16'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '3.13'
68
+ version: '3.16'
69
69
  description: feedparser - web feed parser and normalizer (RSS 2.0, Atom, etc.)
70
70
  email: feedreader@googlegroups.com
71
71
  executables: []
@@ -75,21 +75,23 @@ extra_rdoc_files:
75
75
  - Manifest.txt
76
76
  - README.md
77
77
  files:
78
- - ".gemtest"
79
78
  - HISTORY.md
80
79
  - Manifest.txt
81
80
  - README.md
82
81
  - Rakefile
83
82
  - lib/feedparser.rb
84
83
  - lib/feedparser/builder/atom.rb
84
+ - lib/feedparser/builder/json.rb
85
85
  - lib/feedparser/builder/rss.rb
86
86
  - lib/feedparser/feed.rb
87
87
  - lib/feedparser/item.rb
88
88
  - lib/feedparser/parser.rb
89
89
  - lib/feedparser/version.rb
90
+ - test/feeds/byparker.json
90
91
  - test/feeds/googlegroups.atom
91
92
  - test/feeds/googlegroups2.atom
92
93
  - test/feeds/headius.atom
94
+ - test/feeds/jsonfeed.json
93
95
  - test/feeds/lambdatheultimate.rss2
94
96
  - test/feeds/railstutorial.atom
95
97
  - test/feeds/rubyflow.rss2
@@ -99,6 +101,7 @@ files:
99
101
  - test/helper.rb
100
102
  - test/test_atom.rb
101
103
  - test/test_atom_live.rb
104
+ - test/test_json.rb
102
105
  - test/test_rss.rb
103
106
  - test/test_rss_live.rb
104
107
  homepage: https://github.com/feedreader/feed.parser
@@ -123,12 +126,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
123
126
  version: '0'
124
127
  requirements: []
125
128
  rubyforge_project:
126
- rubygems_version: 2.4.2
129
+ rubygems_version: 2.6.7
127
130
  signing_key:
128
131
  specification_version: 4
129
132
  summary: feedparser - web feed parser and normalizer (RSS 2.0, Atom, etc.)
130
- test_files:
131
- - test/test_atom.rb
132
- - test/test_rss_live.rb
133
- - test/test_rss.rb
134
- - test/test_atom_live.rb
133
+ test_files: []
data/.gemtest DELETED
File without changes