def before_all(context): chroma_settings() import django django.setup() # Take a TestRunner hostage. # Use django_nose's runner so that we can take advantage of REUSE_DB=1. from django_nose import NoseTestSuiteRunner # We'll use these later to frog-march Django through the motions # of setting up and tearing down the test environment, including # test databases. context.runner = NoseTestSuiteRunner()
def before_all(context): chroma_settings() ### Take a TestRunner hostage. # Use django_nose's runner so that we can take advantage of REUSE_DB=1. from django_nose import NoseTestSuiteRunner # We'll use these later to frog-march Django through the motions # of setting up and tearing down the test environment, including # test databases. context.runner = NoseTestSuiteRunner() # If you use South for migrations, uncomment this to monkeypatch # syncdb to get migrations to run. from south.management.commands import patch_for_test_db_setup patch_for_test_db_setup()
import json import glob import shutil import errno import requests # without GNU readline, raw_input prompt goes to stderr import readline assert readline from collections import namedtuple from chroma_core.lib.util import chroma_settings settings = chroma_settings() import django django.setup() from django.contrib.auth.models import User, Group from django.core.management import ManagementUtility from django.contrib.sessions.models import Session from django.core.validators import validate_email from django.core.exceptions import ValidationError from tastypie.models import ApiKey from kombu.connection import BrokerConnection from chroma_core.services.crypto import Crypto