test cases for admin user management, analytics and notification

This commit is contained in:
abutalib-kiwi
2023-09-12 14:51:28 +05:30
parent 2444b6f55e
commit 7aee372606

View File

@ -300,24 +300,21 @@ def make_special_password(length=10):
lowercase_letters = string.ascii_lowercase
uppercase_letters = string.ascii_uppercase
digits = string.digits
special_characters = '!@#$%^&*()_-+=<>?/[]{}|'
special_characters = '@#$%&*?'
# Combine character sets
alphabets = lowercase_letters + uppercase_letters
# Create a password with random characters
password = (
secrets.choice(lowercase_letters) +
password = [
secrets.choice(uppercase_letters) +
secrets.choice(lowercase_letters) +
secrets.choice(digits) +
secrets.choice(special_characters) +
''.join(secrets.choice(alphabets) for _ in range(length - 4))
)
]
# Shuffle the characters to make it more random
password_list = list(password)
random.shuffle(password_list)
return ''.join(password_list)
return ''.join(password)
def task_status_fun(status_value):
"""task status"""