예제 #1
0
 def setUp(self):
     self.old_models = conf.MODELS
     conf.MODELS = {
         'u': 'shorturl.URL',
         'p': 'shorturl.Person',
     }
     conf.set_prefixes(conf.MODELS)
예제 #2
0
 def tearDown(self):
     if self.old_models is not None:
         conf.MODELS = self.old_models
         conf.set_prefixes(self.old_models)
예제 #3
0
 def setUp(self):
     self.old_models = conf.MODELS
     conf.MODELS = {"u": "shorturl.URL"}
     conf.set_prefixes(conf.MODELS)