diff options
author | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-05 03:03:05 +0000 |
---|---|---|
committer | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-05 03:03:05 +0000 |
commit | 71976790ec02f88d9fb51fab151312124f6df223 (patch) | |
tree | 0a70c0031e53d40f05e846486b25f91070274d66 /test/rss/test_maker_2.0.rb | |
parent | 43009063c70fe62028eb035e67a06863b98dc540 (diff) | |
download | ruby-71976790ec02f88d9fb51fab151312124f6df223.tar.gz |
* lib/rss, sample/rss, test/rss:
- 0.1.7 -> 0.1.8.
- supported <itunes:XXX>.
- reverted backward incompatibility API changes introduced 0.1.7.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12871 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/rss/test_maker_2.0.rb')
-rw-r--r-- | test/rss/test_maker_2.0.rb | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/test/rss/test_maker_2.0.rb b/test/rss/test_maker_2.0.rb index 605d439a68..8fd9134f70 100644 --- a/test/rss/test_maker_2.0.rb +++ b/test/rss/test_maker_2.0.rb @@ -353,7 +353,7 @@ module RSS assert_nil(rss.image) end - def test_items + def test_items(with_convenience_way=true) title = "TITLE" link = "http://hoge.com/" description = "text hoge fuga" @@ -407,7 +407,11 @@ module RSS end end maker.items.do_sort = Proc.new do |x, y| - y.title.content[-1] <=> x.title.content[-1] + if with_convenience_way + y.title[-1] <=> x.title[-1] + else + y.title {|t| t.content[-1]} <=> x.title {|t| t.content[-1]} + end end end assert_equal(item_size, rss.items.size) @@ -422,6 +426,10 @@ module RSS end end + def test_items_with_new_api_since_018 + test_items(false) + end + def test_guid isPermaLink = "true" content = "http://inessential.com/2002/09/01.php#a2" |