def test_set_password_raw_ok(self): fu = FacilityUser(username="******") dbg_mode = settings.DEBUG settings.DEBUG = True fu.set_password(raw_password="******") settings.DEBUG = dbg_mode self.assertTrue(fu.check_password("blah"))
def test_set_password_hash_ok(self): fu = FacilityUser(username="******") dbg_mode = settings.DEBUG settings.DEBUG = True fu.set_password(hashed_password=self.__class__.hashed_blah) settings.DEBUG = dbg_mode self.assertTrue(fu.check_password("blah"))
def test_set_password_raw_ok(self): fu = FacilityUser(username="******") dbg_mode = settings.DEBUG; settings.DEBUG=True fu.set_password(raw_password="******") settings.DEBUG = dbg_mode self.assertTrue(fu.check_password("blah"))
def test_set_password_hash_ok(self): fu = FacilityUser(username="******") dbg_mode = settings.DEBUG; settings.DEBUG=True fu.set_password(hashed_password=self.__class__.hashed_blah) settings.DEBUG = dbg_mode self.assertTrue(fu.check_password("blah"))