Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Polyfactory for Creating Mock Users #59

Merged
merged 5 commits into from
Sep 7, 2024
Merged

Conversation

fullerzz
Copy link
Owner

@fullerzz fullerzz commented Sep 7, 2024

Changes

  • Removed test for read_root
  • Switched tests from using @pytest.mark.asyncio --> @pytest.mark.anyio
  • Created a factories.py file in the tests directory containing a UserFactory polyfactory for mocking user data

@fullerzz fullerzz added the dependencies Pull requests that update a dependency file label Sep 7, 2024
@fullerzz fullerzz self-assigned this Sep 7, 2024
@fullerzz fullerzz merged commit 16a9455 into enhance-security Sep 7, 2024
4 checks passed
@fullerzz fullerzz deleted the polyfactory branch September 7, 2024 22:03
fullerzz added a commit that referenced this pull request Sep 7, 2024
* added additional logging

* disable account creation and file uploads temporarily

* system now only allows user file upload if user is whitelisted and user has uploaded less than daily amount of bytes

* hard limit on total number of users allowed to be created as another form of security

* added USER_LIMIT to testing env file

* added invoke task show-users-table

* updated show-users-table invoke task

* fix: user_limit -> users_limit

* removed constant DAILY_UPLOAD_LIMIT_BYTES from operation_validator and instead retrieving value from get_settings()

* wip

* Polyfactory for Creating Mock Users (#59)

* wip: trying to isolate users from one another in test scenarios. todo: generate mock users using polyfactory

* upgraded packages

* fixed all tests except test_user_creation_limit

* added new factories.py file

* updated mypy ignore comment

* updated project version to 0.6.0

* updated requirements and added pyinvoke task for updating requirements.txt with the deps from uv's lockfile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant