[Python] Loading SQL dump before running Django tests

Discussão em 'Python' iniciado por Stack, Março 19, 2025.

  1. Stack

    Stack Membro Participativo

    I have a fairly complex Django project which makes it hard/impossible to use fixtures for loading data.

    What I would like to do is to load a database dump from the production database server after all tables has bene created by the testrunner and before the actual tests start running.

    I've tried various "magic" in MyTestCase.setUp(), but with no luck.

    Any suggestions would be most welcome. Thanks.

    Continue reading...

Compartilhe esta Página