Пример #1
0
 def setUp(self):
     super(ReadLinksTestCase, self).setUp()
     self.line_start = ":[email protected] PRIVMSG #psywerx "
     self.plugin = ReadLinks(bot=self.bot)
     self.say = self.plugin.bot.say
     self.video_response = {'seconds': '34227', 'rating': 'no rating',
                            'views': '385293', 'service': 'youtube',
                            'title': 'ASP 2014 J-Bay Open English Day 10'}
Пример #2
0
    def __init__(self, bot):
        self.bot = bot  # reference back to asynchat handler
        self.joined_channel = False
        self.usertrim = re.compile('[!+@]')
        self.bot.known_users = {}  # dict of known users present in the channel

        self.plugins = [
            PsywerxHistory(bot=bot),
            PsywerxKarma(bot=bot),
            PsywerxGroups(bot=bot),
            NSFWImageDetectorPlugin(bot=bot),
            ReadLinks(bot=bot),
            Uptime(bot=bot),
        ]