MCPcopy
hub / github.com/fastapi/full-stack-fastapi-template / create_random_user

Function create_random_user

backend/tests/utils/user.py:22–27  ·  view source on GitHub ↗
(db: Session)

Source from the content-addressed store, hash-verified

20
21
22def create_random_user(db: Session) -> User:
23 email = random_email()
24 password = random_lower_string()
25 user_in = UserCreate(email=email, password=password)
26 user = crud.create_user(session=db, user_create=user_in)
27 return user
28
29
30def authentication_token_from_email(

Callers 2

create_random_itemFunction · 0.90

Calls 3

random_emailFunction · 0.90
random_lower_stringFunction · 0.90
UserCreateClass · 0.90

Tested by 1