Commit graph

31 commits

Author SHA1 Message Date
Henry Walshaw
66f8bdb45e Fix errors from make test
One Python 2.7 error in the test (didn’t work for points)

Also fixed all the formatting errors raised by flake8
2019-07-29 10:24:02 +10:00
Henry Walshaw
9586e7bcf1 Add a unit test to confirm all coordinates
Make sure that all the required coordinates are in the GeoRSS string,
to avoid the mistake made earlier.
2019-07-08 15:39:33 +10:00
Henry Walshaw
b02278e536 Fix a really dumb formatting issue for the geom_interface
Use the old formatting tag instead of the new when creating geom text
from the geo_interface. Tests updated as well
2019-07-08 15:16:20 +10:00
Henry Walshaw
8cd50bf768 Add unit tests for simple GeoRSS
Also fix a couple of bugs that came up during testing - mostly making
sure that elevation, floor and radius are actually set as strings in
the XML
2019-07-08 14:58:21 +10:00
Henry Walshaw
d32487f2ed Separate extensions as their own files
Give each extension its own test file. Primarily this is done to make
it easier to add some fixtures and extend the geo tests.
2019-07-08 13:49:56 +10:00
Lars Kiesow
c6c7165a97
Add Source Element to Feed Entries
This patch implements the source element for feed entries/items. Note
that only the set of RSS elements (URL and title) are implemented right
now. ATOM supports additional elements which cannot be set at the
moment.

This fixes #79
2018-08-12 21:07:47 +02:00
Lars Kiesow
7a053dc74c
Consistent method naming
This patch renames the entries `pubdate` method to `pubDate` to be
consistent with the feed's method as well as the documentation. Note
that for now, the old method is preserved as well but is marked as
deprecated and to be removed.

This fixes #71
2018-04-29 21:11:30 +02:00
Lars Kiesow
27e9cd0c9a
Fixed GeoRSS Extemsion
This patch fixes a few issues with pzll request #66 which adds supprt
for a simple GeoRSS extension.
2018-03-04 22:55:57 +01:00
Lars Kiesow
2d9e85d956 Merge branch 'bobbrez/add-simple-georss' of https://github.com/bobbrez/python-feedgen 2018-03-04 22:44:38 +01:00
Lars Kiesow
dd15d63fbc
Fix Travis Builds
This patch fixes the Travis builds which were broken due to new Flake8
versions which complained about previously accepted code.
2018-03-04 20:10:01 +01:00
Lars Kiesow
9026316391
Use isort to sort import
…so that they all have the same structure.
2018-03-04 20:05:29 +01:00
Lars Kiesow
9f05e108b5
Merge branch 'issue-60-guid-permalink-attr' 2017-10-14 21:24:09 +02:00
Lars Kiesow
ebb44be9b2 Make Author's Name Optional
RSS does not require an author's name, but only his email address. This
patch makes the name optional for RSS. Note that the name is required in
ATOM feeds and an author will not be included if the name is missing.

This fixes #59
2017-10-14 19:58:37 +02:00
Lars Kiesow
281765fefd
Add Permalink Attribute To RSS GUID
The `isPermalink` attribute can now be set using the `guid()` function
for entries. Note that this only effects RSS feeds. This patch does not
change Atom feeds in any way.

This fixes #60
2017-10-14 19:51:02 +02:00
Bob Breznak
ae5759d133 Better format Geo and GeoEntry. Add test for Geo Extension 2017-09-12 15:50:05 -04:00
Lars Kiesow
4a0a2663e9
Enable Multiple media:thumbnail Elements
As with media:content, there can be multiple media:thumbnail elements in
an item and in multiple groups. This patch adds the ability to do this
in the same manner as with the content.

Part of #58
2017-05-21 23:56:56 +02:00
Lars Kiesow
4970dab6d7
Enable Multiple media:content/media:group Elements
One item can have multiple media:content elements which may be located
in multiple media:group element to indicate that content is the same but
for the format.

This patch adds the ability to add multiple content elements and define
the group to which they go belong.

If no group is specified, all elements are located in a `default` group.

If the group is set to None, the content element is directly attached to
the item element.

Part of #58
2017-05-21 23:56:35 +02:00
Lars Kiesow
a7ae36cb4f
Remove redundant media from method name
Using `fe.media.media_content(…)` is quite redundant. iThis patch
changes the name to `fe.media.content(…)`. The same goes for the
thumbnail method.

Part of #58
2017-05-21 23:56:12 +02:00
Lars Kiesow
8487af298e
Add Media RSS to RSS
This patch adds the necessary RSS extension to ensure that added Media
RSS elements end up in the resulting RSS XML.

Part of #58
2017-05-21 23:55:49 +02:00
Stefan Bisplinghoff
f0c066af0f Unit Tests: Temporary file handles need to be closed explicitly under Windows 2017-03-16 16:33:50 +01:00
Lars Kiesow
688b1d53c4
Fixed flake8 complaint
Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-03-13 21:02:38 +01:00
Lars Kiesow
c633fd4d64
Add tests for feedgen:main
This patch adds some tests for the main routine of feedgen.

Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-03-13 21:02:02 +01:00
Lars Kiesow
fee00f3337
More Feed Tests
Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-03-13 20:57:12 +01:00
Lars Kiesow
8901310fa0
Added Torrent Tests
This patch adds tests for the torrent extension. It also fixes a minor
bug discovered by the new tests.

Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-03-13 20:55:14 +01:00
Lars Kiesow
4c763dc832
Added more tests
Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-02-05 22:46:43 +01:00
Lars Kiesow
4314475bfb
Extended test Coverage
This patch extends the test coverage of the unit tests. It also enables
python-coverage and coveralls to track unit test coverage.

There are some additional minor issue fixed discovered during the test
creation.

Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-02-05 22:03:02 +01:00
Lars Kiesow
444855a248
Flake8 Compatibility
This patch makes the feedgen flake8 compatible, fixing some minor issues
along the way. Most noticeable, this switches from tabs to spaces.

Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2017-01-05 00:39:33 +01:00
Zhiming Wang
9f4431880e
Rename url to uri in Atom feeds
According to RFC 4287, there is no atom:url element, only atom:uri, so
replace occurrences of atom:url with atom:uri for compliance.

Also rename variables holding atom:uri from email to uri to better
indicate what they actually are.
2016-12-19 01:11:33 -05:00
Lars Kiesow
b4400146ea
Fixed Podcast Extension API incompatibility
This patch ensures the compatibility of setting categories for itunes
podcasts even though the new API now supports setting multiple
(sub-)categories.

It also fixes the docs and adjusts them to explicitly mark the old
syntax as deprecated.

Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2016-09-04 18:56:30 +02:00
Lars Kiesow
a9f561bff9
Added unit tests for Itunes extension
Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2016-09-04 17:49:07 +02:00
Lars Kiesow
44cd92837d
Update distribution setup
Signed-off-by: Lars Kiesow <lkiesow@uos.de>
2016-08-29 00:33:10 +02:00