MCPcopy
hub / github.com/django/django / test_bytes

Method test_bytes

tests/auth_tests/test_hashers.py:73–77  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

71 self.assertIs(await acheck_password(" ", blank_encoded), False)
72
73 def test_bytes(self):
74 encoded = make_password(b"bytes_password")
75 self.assertTrue(encoded.startswith("pbkdf2_sha256$"))
76 self.assertIs(is_password_usable(encoded), True)
77 self.assertIs(check_password(b"bytes_password", encoded), True)
78
79 def test_invalid_password(self):
80 msg = "Password must be a string or bytes, got int."

Callers

nothing calls this directly

Calls 3

make_passwordFunction · 0.90
is_password_usableFunction · 0.90
check_passwordFunction · 0.90

Tested by

no test coverage detected