def test_bot_tags_not_interactive(self): bot = {} bot['tags'] = "twitter" bot['location'] = "https://twitter.com/botwikidotorg" tags = botsheeter.bot_tags(bot) self.assertEqual( tags, "twitter,twitterbot,bot,inactive")
def test_bot_tags(self): bot = {} bot['tags'] = "Political, media, corbyn, twitter,headlines" bot['location'] = "https://twitter.com/botwikidotorg" tags = botsheeter.bot_tags(bot) self.assertEqual( tags, "twitter,twitterbot,bot,inactive,political,media,corbyn," "headlines")
def test_bot_tags_authors_twitter_name(self): bot = {} bot['tags'] = "Political, media, corbyn, twitter,headlines" bot['location'] = "https://twitter.com/botwikidotorg" bot['creator_twitter_url'] = "https://twitter.com/fourtonfish" tags = botsheeter.bot_tags(bot) self.assertEqual( tags, "twitter,twitterbot,bot,inactive,political,media,corbyn," "headlines,fourtonfish")
def test_bot_tags_open_source_language(self): bot = {} bot['tags'] = "Political, media, corbyn, twitter,headlines" bot['location'] = "https://twitter.com/botwikidotorg" bot['is_open_source'] = True bot['open_source_language'] = "python" tags = botsheeter.bot_tags(bot) self.assertEqual( tags, "twitter,twitterbot,bot,inactive,political,media,corbyn," "headlines,open source,opensource,python")
def test_bot_tags_nodejs(self): bot = {} bot['tags'] = "media, node, twitter,headlines" bot['location'] = "https://twitter.com/botwikidotorg" bot['is_open_source'] = True bot['open_source_language'] = "node" tags = botsheeter.bot_tags(bot) self.assertEqual( tags, "twitter,twitterbot,bot,inactive,media,node,headlines," "open source,opensource,nodejs,node.js")