Skip to content

database creation not happening for LiveServerTestCase? #79

Closed
@hjwp

Description

@hjwp

Am in Holger's py.test tutorial at the PyCon. Thought I'd try to get py.test working on a small test repo, and it looks like django.test.TestCase tests are working fine, including those that need the test database, but classes from django.test.LiveServerTestCase seem not to be seeing the test database...

Maybe I'm just confused?

here's the test repo: https://github.com/hjwp/book-example/tree/chapter_07

you'll need a virtualenv built with python3, django 1.7 beta, and selenium:

mkvirtualenv pytest-py3-superlists --python=python3
pip install selenium pytest pytest-django https://www.djangoproject.com/download/1.7b1/tarball/

and then

py.test lists/tests.py  # normal django tests, work fine
py.test functional_tests.py  # liveserver tests, fail seemingly because no db

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions