A lax Web news feed parser
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

54 lines
1.6 KiB

Empty entry:
input: >
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://channel.netscape.com/rdf/simple/0.9/">
<channel>
<item/>
</channel>
<item/>
</rdf:RDF>
output:
format: rdf
version: '0.90'
Entry link:
input: >
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://channel.netscape.com/rdf/simple/0.9/">
<channel>
<item>
<link>http://example.com/</link>
</item>
</channel>
<item>
<link>http://example.com/</link>
</item>
</rdf:RDF>
output:
format: rdf
version: '0.90'
entries:
- link: 'http://example.com/'
- link: 'http://example.com/'
Entry title:
input: >
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://channel.netscape.com/rdf/simple/0.9/">
<item>
<title>Loose title</title>
</item>
</rdf:RDF>
output:
format: rdf
version: '0.90'
entries:
- title: {loose: 'Loose title'}
Entry content: # RSS 0.90 didn't have entry descriptions
input: >
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://channel.netscape.com/rdf/simple/0.9/">
<item>
<description>Bogus description</description>
</item>
</rdf:RDF>
output:
format: rdf
version: '0.90'