diff options
| author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-09-11 21:57:31 +0200 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-09-18 22:12:40 +0200 |
| commit | 00e187961059a0e77403151d2bb38c217101d5af (patch) | |
| tree | 085b1e7ce0aa801cc6d13e050ffa126a079feb5a /tests/auth_tests/test_models.py | |
| parent | 295467c04ab4c26a1a9d3798b1e941003fa116cf (diff) | |
Refs #33764 -- Removed BaseUserManager.make_random_password() per deprecation timeline.
Diffstat (limited to 'tests/auth_tests/test_models.py')
| -rw-r--r-- | tests/auth_tests/test_models.py | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/tests/auth_tests/test_models.py b/tests/auth_tests/test_models.py index 19454ade65..b9a006f96d 100644 --- a/tests/auth_tests/test_models.py +++ b/tests/auth_tests/test_models.py @@ -20,8 +20,6 @@ from django.db import connection, migrations from django.db.migrations.state import ModelState, ProjectState from django.db.models.signals import post_save from django.test import SimpleTestCase, TestCase, TransactionTestCase, override_settings -from django.test.utils import ignore_warnings -from django.utils.deprecation import RemovedInDjango51Warning from .models import CustomEmailField, IntegerUsernameUser @@ -168,19 +166,6 @@ class UserManagerTestCase(TransactionTestCase): is_staff=False, ) - @ignore_warnings(category=RemovedInDjango51Warning) - def test_make_random_password(self): - allowed_chars = "abcdefg" - password = UserManager().make_random_password(5, allowed_chars) - self.assertEqual(len(password), 5) - for char in password: - self.assertIn(char, allowed_chars) - - def test_make_random_password_warning(self): - msg = "BaseUserManager.make_random_password() is deprecated." - with self.assertWarnsMessage(RemovedInDjango51Warning, msg): - UserManager().make_random_password() - def test_runpython_manager_methods(self): def forwards(apps, schema_editor): UserModel = apps.get_model("auth", "User") |
