コード例 #1
0
ファイル: run_tests.py プロジェクト: assekalala/gap
#!/usr/bin/env python
"""
simple shortcut for running nosetests via python
replacement for *.bat or *.sh wrappers
"""
import sys
import os
from os.path import dirname, realpath, join
import logging
import nose
import re

from gap.utils.setup import fix_sys_path, setup_testbed

app_path = dirname(realpath(__file__))
fix_sys_path()
# TESTBED = setup_testbed()
os.chdir(dirname(__file__))
sys.path.insert(0, realpath(dirname(__file__)))

CONFIG = nose.config.Config(
    verbosity=1,
    loggingLevel=logging.WARNING,
    withGae=1,
    withoutSandbox=1,
    gaeApplication=app_path,
    where=realpath(dirname(__file__)),
    # nocapture='NOSE_NOCAPTURE',
    stop=1,
)
コード例 #2
0
ファイル: run_tests.py プロジェクト: krtek/gap
simple shortcut for running nosetests via python
replacement for *.bat or *.sh wrappers
'''
import sys
import os
from copy import copy
from os.path import dirname, realpath, join
import logging

extra_plugins=[]
import re

from gap.utils.setup import fix_sys_path

app_path = join(dirname(dirname(realpath(__file__))), 'src')
fix_sys_path(app_path)
os.chdir(dirname(__file__))
sys.path.insert(0, realpath(dirname(__file__)))
argv = copy(sys.argv)

try:
    import nose
    import webtest
    from nosegae import NoseGAE
except ImportError:
    if sys.__stdin__.isatty():
        print "Missing testing requirements. Shell I install them for you? [Yn] "
        resp = raw_input().strip().lower()
        if not resp or resp in ['y', 'a']:
            import pip
            pip.main(['install', '-r', 'requirements.pip'])
コード例 #3
0
ファイル: run_tests.py プロジェクト: krtek/gap
#!/usr/bin/env python
'''
simple shortcut for running nosetests via python
replacement for *.bat or *.sh wrappers
'''
import sys
import os
from os.path import dirname, realpath, join
import logging
import nose
import re

from gap.utils.setup import fix_sys_path, setup_testbed

app_path = dirname(realpath(__file__))
fix_sys_path()
# TESTBED = setup_testbed()
os.chdir(dirname(__file__))
sys.path.insert(0, realpath(dirname(__file__)))

CONFIG = nose.config.Config(
    verbosity=1,
    loggingLevel=logging.WARNING,
    withGae=1,
    withoutSandbox=1,
    gaeApplication=app_path,
    where=realpath(dirname(__file__)),
    # nocapture='NOSE_NOCAPTURE',
    stop=1,
)