コード例 #1
0
    def tearDown(self):
        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)

        if self.existing:
            from django import conf
            conf.settings = self.mod
コード例 #2
0
    def tearDown(self):
        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)

        if self.existing:
            from django import conf
            conf.settings = self.mod
コード例 #3
0
def teadDownModule():
    # remove all the stuff that django installed
    teardown_test_environment()

    sys.path = context['sys.path']
    util.replace_dict(context['sys.modules'], sys.modules)
    util.replace_dict(context['os.environ'], os.environ)

    destroy_test_db(settings.DATABASE_NAME, 2)
コード例 #4
0
def teadDownModule():
    # remove all the stuff that django installed
    teardown_test_environment()

    sys.path = context['sys.path']
    util.replace_dict(context['sys.modules'], sys.modules)
    util.replace_dict(context['os.environ'], os.environ)

    destroy_test_db(settings.DATABASE_NAME, 2)
コード例 #5
0
def tearDownModule():
    # remove all the stuff that django installed
    teardown_test_environment()

    sys.path = context['sys.path']
    util.replace_dict(context['sys.modules'], sys.modules)
    util.replace_dict(context['os.environ'], os.environ)

    destroy_test_db(settings.DATABASE_NAME, verbosity=0)

    rmtree(storage.location, ignore_errors=True)
コード例 #6
0
ファイル: test_django.py プロジェクト: LiiiQin/test
def tearDownModule():
    if not django:
        return

    # remove all the stuff that django installed
    if teardown_test_environment:
        teardown_test_environment()

    if destroy_test_db:
        destroy_test_db(context['DB_NAME'], verbosity=0)

    if storage:
        rmtree(storage.location, ignore_errors=True)

    sys.path = context['sys.path']
    util.replace_dict(context['sys.modules'], sys.modules)
    util.replace_dict(context['os.environ'], os.environ)
コード例 #7
0
ファイル: test_django.py プロジェクト: startup-one/cogofly
def tearDownModule():
    if not django:
        return

    # remove all the stuff that django installed
    if teardown_test_environment:
        teardown_test_environment()

    if destroy_test_db:
        destroy_test_db(context['DB_NAME'], verbosity=0)

    if storage:
        rmtree(storage.location, ignore_errors=True)

    sys.path = context['sys.path']
    util.replace_dict(context['sys.modules'], sys.modules)
    util.replace_dict(context['os.environ'], os.environ)
コード例 #8
0
ファイル: test_util.py プロジェクト: nervatura/nerva2py
 def tearDown(self):
     replace_dict(self.old_aliases, pyamf.ALIAS_TYPES)
コード例 #9
0
    def tearDown(self):
        PostLoadHookClearingTestCase.tearDown(self)

        del sys.path[0]

        _util.replace_dict(self.mods, sys.modules)
コード例 #10
0
 def tearDown(self):
     replace_dict(self.old_aliases, pyamf.ALIAS_TYPES)
コード例 #11
0
    def tearDown(self):
        ImportsTestCase.tearDown(self)

        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)
        sys.path.remove(self.path)
コード例 #12
0
ファイル: test_adapters.py プロジェクト: cardmagic/PyAMF
    def tearDown(self):
        PostLoadHookClearingTestCase.tearDown(self)

        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)
        sys.path.remove(self.path)
コード例 #13
0
ファイル: test_adapters.py プロジェクト: lukewiersma/redcop
    def tearDown(self):
        PostLoadHookClearingTestCase.tearDown(self)

        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)
        sys.path.remove(self.path)
コード例 #14
0
ファイル: test_adapters.py プロジェクト: startup-one/cogofly
    def tearDown(self):
        ImportsTestCase.tearDown(self)

        util.replace_dict(os.environ, self.old_env)
        util.replace_dict(sys.modules, self.mods)
        sys.path.remove(self.path)