TST: py26 compatible test

pull/519/head
Daniel Black 11 years ago
parent 8a25dd2dad
commit 74567d64b6

@ -67,7 +67,7 @@ class DatabaseTest(unittest.TestCase):
def testUpdateDb(self):
shutil.copyfile('fail2ban/tests/files/database_v1.db', self.dbFilename)
self.db = Fail2BanDb(self.dbFilename)
self.assertEqual(self.db.getJailNames(), {'DummyJail #29162448 with 0 tickets'})
self.assertEqual(self.db.getJailNames(), set(['DummyJail #29162448 with 0 tickets']))
self.assertEqual(self.db.getLogPaths(), {'/tmp/Fail2BanDb_pUlZJh.log'})
ticket = FailTicket("127.0.0.1", 1388009242.26, [u"abc\n"])
self.assertEqual(self.db.getBans()[0], ticket)

Loading…
Cancel
Save