Faker for pydantic models.
Project description
Pydantricks
Faker for pydantic models.
Start simple
>>> from pydantic import BaseModel
>>> from pydantricks import FieldFactory, ModelFactory
>>>
>>>
>>> class User(BaseModel):
... username: str
...
>>>
>>> class UserFactory(ModelFactory[User]):
... username = FieldFactory.field.user_name
...
>>> UserFactory()
User(username='qmiller')
>>> UserFactory()
User(username='harrisamanda')
>>> UserFactory()
User(username='jamesamy')
pydantricks support composed models as well.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pydantricks-0.1.1.tar.gz
(4.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pydantricks-0.1.1.tar.gz.
File metadata
- Download URL: pydantricks-0.1.1.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: pdm/2.26.6 CPython/3.12.12 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f7362eeebcc7a6503db790d3fb579a118c6d04e02bfd59b9ad00a9f98d96b92c
|
|
| MD5 |
b6346266ba793e54cc636e693b388f31
|
|
| BLAKE2b-256 |
9539d3f3126e971ac92419d42be2bd4aa63779f6ece5f6d128ee95805c9f62de
|
File details
Details for the file pydantricks-0.1.1-py3-none-any.whl.
File metadata
- Download URL: pydantricks-0.1.1-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: pdm/2.26.6 CPython/3.12.12 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e8a36a2115a2de2057b94a8f35d6d1f9109d5d119ed7cafa896af6787b18f1e0
|
|
| MD5 |
cb5e0ac3bd88b914ee3d4ad10d70ba30
|
|
| BLAKE2b-256 |
e3b4ecfa3a04b261e826fbd54445ffb619134aba089253926f10b5948c941799
|