From b98e52378eabe71313fe813d2250a170d9658e01 Mon Sep 17 00:00:00 2001 From: Kodjo Sossouvi Date: Sun, 26 Oct 2025 20:26:32 +0100 Subject: [PATCH] Adding test for LoginPage --- .gitignore | 1 + src/Users.db | Bin 40960 -> 0 bytes src/main.py | 2 +- src/myfasthtml/auth/pages/RegisterPage.py | 9 + src/myfasthtml/auth/routes.py | 14 +- src/myfasthtml/core/testclient.py | 328 ++++++++++ tests/auth/__init__.py | 0 tests/auth/test_login.py | 39 ++ tests/auth/test_register.py | 0 tests/auth/test_utils.py | 33 + tests/testclient/__init__.py | 0 tests/{ => testclient}/test_mytestclient.py | 0 .../{ => testclient}/test_testable_element.py | 0 tests/testclient/test_testable_form.py | 585 ++++++++++++++++++ 14 files changed, 1003 insertions(+), 8 deletions(-) delete mode 100644 src/Users.db create mode 100644 tests/auth/__init__.py create mode 100644 tests/auth/test_login.py create mode 100644 tests/auth/test_register.py create mode 100644 tests/auth/test_utils.py create mode 100644 tests/testclient/__init__.py rename tests/{ => testclient}/test_mytestclient.py (100%) rename tests/{ => testclient}/test_testable_element.py (100%) create mode 100644 tests/testclient/test_testable_form.py diff --git a/.gitignore b/.gitignore index 4d06a41..7fae7a4 100644 --- a/.gitignore +++ b/.gitignore @@ -22,6 +22,7 @@ tools.db .idea/sqldialects.xml .idea_bak **/*.prof +**/*.db # Created by .ignore support plugin (hsz.mobi) ### Python template diff --git a/src/Users.db b/src/Users.db deleted file mode 100644 index ecb1569a3700d724bec453ff8078556f0c54f88f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 40960 zcmeI)%}?8A90zba0YcE2*UKzab;<#$APDu_V>?LEnw7MI^4?@^S51)$DX2LgpG%Kufr$)$m_V5W8B=qx8uS;TsHj| zm;FunUHCb>H2g#M%JA6GBQ^;G1R(I{1Uf=CBN`KY=YhLt)5os;xE6RjbkDER$NO%J z`ZX))P8hqfSuRz|xy99m^1WQ&f@8V3VQn?nZDs0Zv(x>HcRn1=h=fJ7b26gf$v&;M zecI|am5mGNuw4HR!Wdu16SY+ftIX!Ywrj2(7uZN9Bg!nWwUdGM>UF~!jSH(+>MTJe z2l7p3I3rF>@ZYU`e^Fu59|=wf*MJO<(%VtC|l!|MF`^Qb=Bw z@`_%O^?9Ps6KPI1l!9i&&k4We=Y>Bx_P_uE2tWV=5P$##AOHafKmY;|fWQS4xSFnJ z&vMqHd;I^L6P{nN1w^