#35322: Slow feedback loop in tests using Postgres
-----------------------------------------+------------------------
               Reporter:  Martin Lehoux  |          Owner:  nobody
                   Type:  Uncategorized  |         Status:  new
              Component:  Uncategorized  |        Version:  5.0
               Severity:  Normal         |       Keywords:
           Triage Stage:  Unreviewed     |      Has patch:  0
    Needs documentation:  0              |    Needs tests:  0
Patch needs improvement:  0              |  Easy pickings:  0
                  UI/UX:  0              |
-----------------------------------------+------------------------
 I have a growing codebase, and the tests are getting slower and slower. My
 main concern is when iterating on a small test case, the overhead of
 running tests is the largest part of the runtime (as opposed to running
 all tests in continuous integration). I am running tests with pytest-
 django, my database is a postgres running in a docker-compose.

 My baseline was 20sec with --keedp-db. I made some improvements that were
 easily accessible : --no-migration gave me a 3sec improvement.

 But while digging into the code, it seems that whatever options I provide,
 I cannot skip the `call_command("migrate" ...)` part. I wonder why this is
 the case, because commenting this part gave me a 5.5 sec improvement.

 I must say my django startup time has risen up a lot, at around 5 sec.

 Is there something I'm missing about running small tests?
-- 
Ticket URL: <https://code.djangoproject.com/ticket/35322>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018e618b6a66-f517743d-d550-4697-bee2-f78211ceb450-000000%40eu-central-1.amazonses.com.

Reply via email to