diff options
| author | Max Nanis | 2026-08-18 13:14:45 -0700 |
|---|---|---|
| committer | Max Nanis | 2026-08-18 13:14:45 -0700 |
| commit | 6b4f8d6b8700a65bdf74beb3d95c969a81464a56 (patch) | |
| tree | 09c0b32c8915f4ffa5c5e02222c49cbf591f8588 /tests/models/thl/test_user.py | |
| parent | c6f7ad8baaa8e0e22dfcefc763f4065faf6de507 (diff) | |
| download | generalresearch-6b4f8d6b8700a65bdf74beb3d95c969a81464a56.tar.gz generalresearch-6b4f8d6b8700a65bdf74beb3d95c969a81464a56.zip | |
build ignore, py-utils replace, typing with Ruff
Diffstat (limited to 'tests/models/thl/test_user.py')
| -rw-r--r-- | tests/models/thl/test_user.py | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/tests/models/thl/test_user.py b/tests/models/thl/test_user.py index 4f10861..25af694 100644 --- a/tests/models/thl/test_user.py +++ b/tests/models/thl/test_user.py @@ -1,7 +1,8 @@ import json -from datetime import datetime, timezone, timedelta +from datetime import datetime, timedelta, timezone from decimal import Decimal -from random import randint, choice as rand_choice +from random import choice as rand_choice +from random import randint from uuid import uuid4 import pytest @@ -315,7 +316,7 @@ class TestUserUUID: with pytest.raises(ValueError) as cm: User(user_id=self.user_id, uuid=Decimal("0")) - assert "1 validation error for User", str(cm.value) + assert "1 validation error for User" in str(cm.value) assert "Input should be a valid string" in str(cm.value) def test_empty(self): @@ -323,8 +324,8 @@ class TestUserUUID: with pytest.raises(ValueError) as cm: User(user_id=self.user_id, uuid="") - assert "1 validation error for User", str(cm.value) - assert "String should have at least 32 characters", str(cm.value) + assert "1 validation error for User" in str(cm.value) + assert "String should have at least 32 characters" in str(cm.value) def test_invalid_len(self): from generalresearch.models.thl.user import User |
