mirror of
https://github.com/LightAir/turbo-rss.git
synced 2026-02-04 03:56:19 +00:00
WIP. Правка тестов
This commit is contained in:
@@ -1 +1 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Untitled RSS Feed]]></title><description><![CDATA[Untitled RSS Feed]]></description><link>http://github.com/dylang/node-rss</link><generator>RSS for Node</generator><lastBuildDate>Wed, 10 Dec 2014 19:04:57 GMT</lastBuildDate></channel></rss>
|
||||
<rss xmlns:yandex="http://news.yandex.ru" xmlns:media="http://search.yahoo.com/mrss/" xmlns:turbo="http://turbo.yandex.ru" version="2.0"><channel><title><![CDATA[Channel Yandex RSS]]></title><link>https://github.com/Lightair/yandex-turbo</link><description><![CDATA[Channel Yandex RSS]]></description><language>ru</language></channel></rss>
|
||||
@@ -1 +1 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Untitled RSS Feed]]></title><description><![CDATA[Untitled RSS Feed]]></description><link>http://github.com/dylang/node-rss</link><generator>RSS for Node</generator><lastBuildDate>Wed, 10 Dec 2014 19:04:57 GMT</lastBuildDate><item><title><![CDATA[No title]]></title><guid isPermaLink="false">No title</guid></item></channel></rss>
|
||||
<rss xmlns:yandex="http://news.yandex.ru" xmlns:media="http://search.yahoo.com/mrss/" xmlns:turbo="http://turbo.yandex.ru" version="2.0"><channel><title><![CDATA[Untitled RSS Feed]]></title><description><![CDATA[Untitled RSS Feed]]></description><link>http://github.com/dylang/node-rss</link><generator>RSS for Node</generator><lastBuildDate>Wed, 10 Dec 2014 19:04:57 GMT</lastBuildDate><item><title><![CDATA[No title]]></title><guid isPermaLink="false">No title</guid></item></channel></rss>
|
||||
@@ -1,8 +1,8 @@
|
||||
// prova is a wrapper for tape
|
||||
// use npm run test:browser to run tests in a browser
|
||||
var test = require('prova');
|
||||
var test = require('tape');
|
||||
|
||||
var RSS = require('..');
|
||||
var YTurbo = require('..');
|
||||
var xml2js = require('xml2js');
|
||||
var q = require('q');
|
||||
|
||||
@@ -14,7 +14,7 @@ require('mockdate').set('Wed, 10 Dec 2014 19:04:57 GMT');
|
||||
|
||||
test('empty feed', function(t) {
|
||||
t.plan(2);
|
||||
var feed = new RSS();
|
||||
var feed = new YTurbo();
|
||||
t.equal(feed.xml(), expectedOutput.default);
|
||||
feed.item();
|
||||
t.equal(feed.xml(), expectedOutput.defaultOneItem);
|
||||
@@ -22,7 +22,7 @@ test('empty feed', function(t) {
|
||||
|
||||
test('indentation', function(t) {
|
||||
t.plan(4);
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
generator: 'Example Generator',
|
||||
@@ -98,7 +98,7 @@ test('enclosure', function(t) {
|
||||
|
||||
t.plan(1);
|
||||
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
@@ -142,7 +142,7 @@ test('enclosure_mimetype_override', function(t) {
|
||||
|
||||
t.plan(1);
|
||||
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
@@ -177,7 +177,7 @@ test('enclosure_mimetype_override', function(t) {
|
||||
|
||||
test('geoRSS', function(t) {
|
||||
t.plan(1);
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
@@ -207,7 +207,7 @@ test('geoRSS', function(t) {
|
||||
test('PubSubHubbub hub', function(t) {
|
||||
t.plan(1);
|
||||
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
@@ -222,7 +222,7 @@ test('PubSubHubbub hub', function(t) {
|
||||
test('custom elements', function(t) {
|
||||
t.plan(1);
|
||||
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
@@ -280,7 +280,7 @@ test('custom elements', function(t) {
|
||||
test('custom namespaces', function(t) {
|
||||
t.plan(1);
|
||||
|
||||
var feed = new RSS({
|
||||
var feed = new YTurbo({
|
||||
title: 'title',
|
||||
description: 'description',
|
||||
feed_url: 'http://example.com/rss.xml',
|
||||
|
||||
Reference in New Issue
Block a user