htmlToTexted the team.

This commit is contained in:
Jeremy Fincher 2004-02-09 16:42:28 +00:00
parent e6f1b6e7ee
commit 03084065d6
2 changed files with 4 additions and 0 deletions

View File

@ -125,6 +125,7 @@ class Gameknot(callbacks.PrivmsgCommandAndRegexp):
games = '%s active games' % games
if 'Team:' in profile:
team = self._gkteam.search(profile).group('name')
team = utils.htmlToText(team)
s = '%s (team: %s) is rated %s and has %s ' \
'and a record of %s, %s, and %s ' \
'(win/loss/draw percentage: %.2f%%/%.2f%%/%.2f%%). %s' % \

View File

@ -41,6 +41,9 @@ if network:
self.assertError('gkstats %s' % utils.mktemp())
self.assertNotError('gkstats Strike')
def testNoHtmlInTeam(self):
self.assertNotRegexp('gkstats jeffuk', '9608')
def testUrlSnarfer(self):
conf.supybot.plugins.Gameknot.gameSnarfer.setValue(True)
self.assertNotError('http://gameknot.com/chess.pl?bd=1019508')