-

Welcome to report documentation!

+

report package

report (Report Module)

Author:

@@ -206,7 +232,8 @@
class report.JsonFormatter(fmt=None, datefmt=None, style='%', validate=True, *, defaults=None)
-
+

Bases: Formatter

+
format(record)

Format the specified record as text.

@@ -270,6 +297,21 @@ it is formatted using formatException() and appended to the message.

Testcase level (smoke), this is just a rough test for the main functionality

+
+
+report.add_handler_file(logger: Logger, filename: str, maxMbytes: int, backupCount: int, level: int = 10, fmt: str = '%(asctime)s: %(levelname)8s - %(name)s - %(message)s\n                                    File "%(pathname)s", line %(lineno)d, in %(funcName)s') RotatingFileHandler
+
+ +
+
+report.add_handler_socket(logger: Logger, level: int = 10, host: str = 'localhost', port: int = 19996) SocketHandler
+
+ +
+
+report.add_handler_stdout(logger: Logger, level: int = 30, fmt: str = '%(asctime)s: %(levelname)8s - %(name)s - %(message)s\n                                    File "%(pathname)s", line %(lineno)d, in %(funcName)s') StreamHandler
+
+
report.app_logging_config()
@@ -279,7 +321,13 @@ it is formatted using formatException() and appended to the message.

class report.collectingHandler
-
+

Bases: Handler

+
+
+MY_LOGS = []
+
+ +
emit(record)

Do whatever it takes to actually log the specified logging record.

@@ -287,17 +335,54 @@ it is formatted using formatException() and appended to the message.

raises a NotImplementedError.

+
+
+get_logs()
+
+ +
+
+get_str(logs=None, fmt='%(asctime)s: %(levelname)8s - %(name)s - %(message)s')
+
+ +
+
+make_independent()
+
+
class report.collectingRingHandler(max_logs=None)
+

Bases: collectingHandler

+
+
+MY_LOGS = deque([], maxlen=10)
+
+
+get_logs()
+
+ +
+
+make_independent()
+
+ +
+
class report.collectingTestcaseHandler
-
+

Bases: collectingHandler

+
+
+MY_LOGS = []
+
+ +
emit(record)

Do whatever it takes to actually log the specified logging record.

@@ -324,18 +409,69 @@ LOG_LEVEL = logging.INFO # STDOUT logging

class report.testSession(module_names=[], **kwargs)
+

Bases: dict

+
+
+DEFAULT_BASE_DATA = {'name': 'Default Testsession name', 'number_of_failed_tests': 0, 'number_of_possibly_failed_tests': 0, 'number_of_successfull_tests': 0, 'number_of_tests': 0, 'testcase_execution_level': 90, 'testcase_names': {0: 'Single Test', 10: 'Smoke Test (Minumum subset)', 50: 'Short Test (Subset)', 90: 'Full Test (all defined tests)'}}
-
-
-
-
-

Indices and tables

- +
+
+KEY_ALL_TESTS = 'number_of_tests'
+
+ +
+
+KEY_EXEC_LVL = 'testcase_execution_level'
+
+ +
+
+KEY_EXEC_NAMES = 'testcase_names'
+
+ +
+
+KEY_FAILED_TESTS = 'number_of_failed_tests'
+
+ +
+
+KEY_LVL_NAMES = 'level_names'
+
+ +
+
+KEY_NAME = 'name'
+
+ +
+
+KEY_POSSIBLY_FAILED_TESTS = 'number_of_possibly_failed_tests'
+
+ +
+
+KEY_SUCCESS_TESTS = 'number_of_successfull_tests'
+
+ +
+
+KEY_TESTCASELIST = 'testcases'
+
+ +
+
+KEY_UID_LIST = 'uid_list_sorted'
+
+ +
+
+testCase(name, testcase_execution_level, test_method, *args, **kwargs)
+
+ + +
@@ -348,7 +484,7 @@ LOG_LEVEL = logging.INFO # STDOUT logging

Table of Contents

This Page

@@ -420,10 +582,10 @@ LOG_LEVEL = logging.INFO # STDOUT logging