File: run_tests.py

package info (click to toggle)
django-haystack 3.3.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,504 kB
  • sloc: python: 23,475; xml: 1,708; sh: 74; makefile: 71
file content (18 lines) | stat: -rwxr-xr-x 377 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env python
import os
import sys

import django
from django.core.management import call_command


def run_all(argv=None):
    sys.path.insert(0, os.path.dirname(os.path.dirname(__file__)))
    os.environ["DJANGO_SETTINGS_MODULE"] = "test_haystack.settings"
    django.setup()

    call_command("test", sys.argv[1:])


if __name__ == "__main__":
    run_all(sys.argv)