From 3f94bf6dae4b5a2e432ea9c9dd68d86fc668a706 Mon Sep 17 00:00:00 2001 From: James Vega Date: Tue, 22 Feb 2005 14:27:59 +0000 Subject: [PATCH] Fix an exception in RSS.announce. --- plugins/RSS/plugin.py | 2 +- plugins/RSS/test.py | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/RSS/plugin.py b/plugins/RSS/plugin.py index ed3e4bf97..ee8c1f913 100644 --- a/plugins/RSS/plugin.py +++ b/plugins/RSS/plugin.py @@ -318,7 +318,7 @@ class RSS(callbacks.Plugin): announce.get(channel).setValue(feeds) irc.replySuccess() elif not rest: - feeds = format('%L', announce.get(channel)()) + feeds = format('%L', list(announce.get(channel)())) irc.reply(feeds or 'I am currently not announcing any feeds.') return announce = wrap(announce, [('checkChannelCapability', 'op'), diff --git a/plugins/RSS/test.py b/plugins/RSS/test.py index afecb57a6..638596ef6 100644 --- a/plugins/RSS/test.py +++ b/plugins/RSS/test.py @@ -56,6 +56,11 @@ class RSSTestCase(ChannelPluginTestCase): self.assertNotRegexp('rss info http://slashdot.org/slashdot.rss', '-1 years') + def testAnnounce(self): + self.assertNotError('rss add advogato %s' % url) + self.assertNotError('rss announce advogato') + self.assertNotRegexp('rss announce', r'ValueError') + def testRss(self): self.assertNotError('rss %s' % url) m = self.assertNotError('rss %s 2' % url)