Open nerdoc opened 1 year ago
Ha, yes. Thats a little embarrassing really...
PyTest (with Playwright for integration) are my preferred tools.
Something I want to do I provide a simple way for devs to setup PyTest/Playwright for their own Tetra components.
Do you want to include tests into the demosite, as there already is a django project to use for tests? I always had problems setting up pytest "standalone", without a full django project (just with those runtests.py, conftest.py etc).
@nerdoc Did you ever start with the tests? Did you also plan to add a CI setup?
If it helps, I could add something like this as a test infrastructure:
pyproject.toml
(replacing setup.py
)tox.ini
)The setup would be similar to what you can find in this Django project example, but with GHA for GitHub.
Interested?
HM, no. As tetra seems to be dead (at least Sam seems to have no time for maintaining it), I switched to using HTMX...
@bittner Wind is changing again ;-) As I took over the development of tetra, I added basic tests, at least for some of the blocks and backend things, see in the "tetra-package" branch (soon to be merged).
I never used tox, but the tests are run with pytest ATM. CI in GH is set up and working as well.
I don't know well how to test the frontend parts. I've never used a Js frontent test engine. MochaJs (X,=nodejs), Jest(X, more for React etc), Jasmine(BDD!), Karma(needs Browser?), Cypress(component testing!!, supported by PyCharm IDE), Selenium (uuuaaargh...)
There are no tests in tetra.
If you tell me what testing framework you prefer (Django unit tests, pytest/pytest-django, etc.) I can help at least with adding some backend tests, , e.g. using the demo site.