def testFindTemplateWithParam(self): template = static.findTemplate('/x/y/z/param.shtml?bla=x',mockTemplates) self.assertEqual(template,'/path/param.shtml$lang$date')
def testFindTemplateNomatch(self): template = static.findTemplate('/x/y/z/xx.shtml?bla=x',mockTemplates) assert not template
def testFindTemplateNoParam(self): template = static.findTemplate('/x/y/z/noparam.shtml',mockTemplates) self.assertEqual(template,'/noparam.shtml')