You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@predictionio.apache.org by do...@apache.org on 2016/08/09 21:43:40 UTC
[32/52] [abbrv] incubator-predictionio git commit: Make --logging
INFO a default
Make --logging INFO a default
Project: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/commit/e0bc06ba
Tree: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/tree/e0bc06ba
Diff: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/diff/e0bc06ba
Branch: refs/heads/develop
Commit: e0bc06ba22dc99af2f680613aa3a744c3e702300
Parents: 92bffaf
Author: Marcin Ziemi\u0144ski <zi...@gmail.com>
Authored: Wed Aug 3 13:08:41 2016 -0700
Committer: Marcin Ziemi\u0144ski <zi...@gmail.com>
Committed: Wed Aug 3 14:42:06 2016 -0700
----------------------------------------------------------------------
tests.py | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-predictionio/blob/e0bc06ba/tests.py
----------------------------------------------------------------------
diff --git a/tests.py b/tests.py
index c84bb08..6364e08 100755
--- a/tests.py
+++ b/tests.py
@@ -2,9 +2,9 @@ import os
import sys
import unittest
import argparse
-import xmlrunner
import logging
import time
+from xmlrunner import XMLTestRunner
import pio_tests.globals as globals
from utils import srun_bg
from pio_tests.integration import TestContext
@@ -20,7 +20,7 @@ parser.add_argument('--no-shell-stdout', action='store_true',
parser.add_argument('--no-shell-stderr', action='store_true',
help='Suppress STDERR output from shell executed commands')
parser.add_argument('--logging', action='store', choices=['INFO', 'DEBUG', 'NO_LOGGING'],
- default='NO_LOGGING', help='Choose the logging level')
+ default='INFO', help='Choose the logging level')
parser.add_argument('--tests', nargs='*', type=str,
default=None, help='Names of the tests to execute. By default all tests will be checked')
@@ -54,7 +54,8 @@ if __name__ == "__main__":
logger.level = logging.DEBUG
test_context = TestContext(
- ENGINE_DIRECTORY, DATA_DIRECTORY, args['eventserver_ip'], int(args['eventserver_port']))
+ ENGINE_DIRECTORY, DATA_DIRECTORY,
+ args['eventserver_ip'], int(args['eventserver_port']))
tests_dict = get_tests(test_context)
test_names = args['tests']
@@ -68,7 +69,8 @@ if __name__ == "__main__":
event_server_process = srun_bg('pio eventserver --ip {} --port {}'
.format(test_context.es_ip, test_context.es_port))
time.sleep(5)
- result = xmlrunner.XMLTestRunner(verbosity=2, output='test-reports').run(unittest.TestSuite(tests))
+ result = XMLTestRunner(verbosity=2, output='test-reports').run(
+ unittest.TestSuite(tests))
event_server_process.kill()
if not result.wasSuccessful():