By the way, does anyone actually run `make test` o...
# general
n
By the way, does anyone actually run
make test
on their own devices? It burns a whole in my RAM when I run it on my laptop
d
I believe Cory does. But I typically just run the specific unit test for my code change, e.g.
Copy code
DAFT_RUNNER=native pytest tests/my/path/test_file.py -s -k "my_test_name"
✅ 1
m
That works well! Make sure you're in the right environment if you do that. You can also just delegate that to
uv
with
uv run pytest
. YMMV but I use this a lot:
Copy code
DAFT_RUNNER=native uv run pytest -v --cov=daft '<FILE(S) TO TEST>'
If you add in
--cov=daft
then it will print a code coverage report in your terminal 🙂 Also, if you're adding new python packages, they won't be picked up unless you get
uv
to sync them again. Since our setup is a bit more complex than a normal Python project, it's necessary to do a
make build
if you're changing Python packages around.
s
I usually run
pytest --last-failed
which only runs the failed tests
💯 2