os-ken/ryu/tests/run_tests.py
Yusuke Iwase 033d99474a .travis.yml: Suppress the output of unit tests
Because Travis-CI has a limit of the log file to 4MB, this patch
suppress the output of unit tests by setting NOSE_VERBOSE in tox.ini.
tox.ini does not effect when running run_tests.sh locally,
so please run run_tests.sh, if the full log messages are needed.

Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2015-09-18 08:31:44 +09:00

36 lines
829 B
Python
Executable File

#!/usr/bin/env python
import os
import sys
from nose import config
from nose import core
sys.path.append(os.getcwd())
sys.path.append(os.path.dirname(__file__))
import ryu.tests.unit
from ryu.tests.test_lib import run_tests
if __name__ == '__main__':
exit_status = False
# if a single test case was specified,
# we should only invoked the tests once
invoke_once = len(sys.argv) > 1
cwd = os.getcwd()
c = config.Config(stream=sys.stdout,
env=os.environ,
verbosity=int(os.environ.get('NOSE_VERBOSE', 3)),
includeExe=True,
traverseNamespace=True,
plugins=core.DefaultPluginManager())
c.configureWhere(ryu.tests.unit.__path__)
exit_status = run_tests(c)
sys.exit(exit_status)