コード例 #1
0
    def __init__(self, comm, config, file, mpi_reporter):
        """
    """
        TerminalReporter.__init__(self, config, file)

        self.comm = comm
        self.mpi_reporter = mpi_reporter
コード例 #2
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.tests_count = 0
     self.reports = []
     self.skipped = []
     self.failed = []
     self.result = StreamResultToBytes(self.writer._file)
コード例 #3
0
ファイル: stats.py プロジェクト: s0undt3ch/pytest-salt
 def __init__(self, config):
     TerminalReporter.__init__(self, config)
     self._session = None
     self._show_sys_stats = config.getoption('--sys-stats') is True
     self._sys_stats_no_children = config.getoption('--sys-stats-no-children') is True
     if config.getoption('--sys-stats-uss-mem') is True:
         self._sys_stats_mem_type = 'uss'
     else:
         self._sys_stats_mem_type = 'rss'
コード例 #4
0
 def __init__(self, builtin):
     # Pass in the builtin reporter's config so we're not redoing all of its
     # initial setup/cli parsing/etc. NOTE: TerminalReporter is old-style :(
     TerminalReporter.__init__(self, builtin.config)
     # Which headers have already been displayed
     # TODO: faster data structure probably wise
     self.headers_displayed = []
     # Size of indents. TODO: configuration
     self.indent = " " * 4
コード例 #5
0
ファイル: pytest_sugar.py プロジェクト: Djailla/pytest-sugar
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.reports = []
     self.unreported_errors = []
     self.progress_blocks = []
     self.reset_tracked_lines()
コード例 #6
0
 def __init__(self, config):
     TerminalReporter.__init__(self, config)
     self._session = None
     self._show_sys_stats = config.getoption("--sys-stats") is True
     self._sys_stats_no_children = config.getoption(
         "--sys-stats-no-children") is True
     if config.getoption("--sys-stats-uss-mem") is True:
         self._sys_stats_mem_type = "uss"
     else:
         self._sys_stats_mem_type = "rss"
コード例 #7
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.reports = []
     self.unreported_errors = []
     self.progress_blocks = []
     self.reset_tracked_lines()
コード例 #8
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.current_line = ''
     self.currentfspath2 = ''
     self.reports = []
     self.unreported_errors = []
     self.progress_blocks = []
コード例 #9
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.current_line = ''
     self.currentfspath2 = ''
     self.time_taken = {}
     self.reports = []
     self.unreported_errors = []
コード例 #10
0
ファイル: pytest_sugar.py プロジェクト: dscerri/pytest-sugar
 def __init__(self, reporter):
     #pytest_collectreport = self.pytest_collectreport
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.eta_logger = EtaLogger()
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.current_line = u''
     self.currentfspath2 = ''
     self.time_taken = {}
     self.reports = []
     self.unreported_errors = []
コード例 #11
0
 def __init__(self, reporter, print_every_x_pass=1):
     TerminalReporter.__init__(self, reporter.config, )
     self.print_every_x_pass = print_every_x_pass
     self._tw = reporter._tw
     self.tests_count = 0
     self.tests_taken = Counter()
     self.pass_count = Counter()
     self.fail_count = Counter()
     self.skip_count = Counter()
     self.xpass_count = Counter()
     self.xfail_count = Counter()
     self.error_count = Counter()
     self.rerun_count = Counter()
コード例 #12
0
 def __init__(self, reporter, manager):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter.writer  # some monkeypatching needed to access existing writer
     self.manager = manager
     self.stats = dict()
     self.stat_keys = [
         'passed', 'failed', 'error', 'skipped', 'warnings', 'xpassed',
         'xfailed', ''
     ]
     for key in self.stat_keys:
         self.stats[key] = manager.list()
     self.stats_lock = manager.Lock()
     self._progress_items_reported_proxy = manager.Value('i', 0)
コード例 #13
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
     self.tests_count = 0
     self.tests_taken = 0
     self.pass_count = 0
     self.fail_count = 0
     self.skip_count = 0
     self.xpass_count = 0
     self.xfail_count = 0
     self.error_count = 0
     self.rerun_count = 0
     self.executed_nodes = []
コード例 #14
0
ファイル: pytest_sugar.py プロジェクト: dscerri/pytest-sugar
 def __init__(self, reporter):
     #pytest_collectreport = self.pytest_collectreport
     TerminalReporter.__init__(self, reporter.config)
     self.writer = self._tw
     self.eta_logger = EtaLogger()
     self.paths_left = []
     self.tests_count = 0
     self.tests_taken = 0
     self.current_line = u''
     self.currentfspath2 = ''
     self.time_taken = {}
     self.reports = []
     self.unreported_errors = []
コード例 #15
0
ファイル: plugin.py プロジェクト: pmneve/pytest-pspec
    def __init__(self, config, file=None):
        TerminalReporter.__init__(self, config, file)
        self._last_header = None
        self.pattern_config = models.PatternConfig(
            files=self.config.getini('python_files'),
            functions=self.config.getini('python_functions'),
            classes=self.config.getini('python_classes'))
        self.result_wrappers = []

        if config.getini('pspec_format') != 'plaintext':
            self.result_wrappers.append(wrappers.UTF8Wrapper)

        if config.option.color != 'no':
            self.result_wrappers.append(wrappers.ColorWrapper)
コード例 #16
0
    def __init__(self, reporter):
        global THEME, LEN_PROGRESS_BAR_SETTING
        TerminalReporter.__init__(self, reporter.config)
        self.writer = self._tw
        self.paths_left = []
        self.tests_count = 0
        self.tests_taken = 0
        self.current_line = ''
        self.currentfspath2 = ''
        self.reports = []
        self.unreported_errors = []
        self.progress_blocks = []

        if self.config.option.color == "no":
            THEME = THEMES['no-color']
        LEN_PROGRESS_BAR_SETTING = self.config.option.progressbar_len
コード例 #17
0
    def __init__(self, config=None, file=None):
        if config:
            # If we have a config, nothing more needs to be done
            return TerminalReporter.__init__(self, config, file)

        # Without a config, pretend to be a TerminalReporter
        # hook-related functions (logreport, collection, etc) will be outrigt broken,
        # but the line writers should still be usable
        if file is None:
            file = sys.stdout

        self._tw = self.writer = TerminalWriter(file)
        self.hasmarkup = self._tw.hasmarkup
        self.reportchars = ''
        self.currentfspath = None
コード例 #18
0
    def __init__(self, config=None, file=None):
        if config:
            # If we have a config, nothing more needs to be done
            return TerminalReporter.__init__(self, config, file)

        # Without a config, pretend to be a TerminalReporter
        # hook-related functions (logreport, collection, etc) will be outrigt broken,
        # but the line writers should still be usable
        if file is None:
            file = sys.stdout

        self._tw = self.writer = TerminalWriter(file)
        self.hasmarkup = self._tw.hasmarkup
        self.reportchars = ''
        self.currentfspath = None
コード例 #19
0
    def __init__(self, reporter):
        """Initialize TerminalReporter without features we don't need.

        :type reporter: :py:class:`_pytest.terminal.TerminalReporter`
        """
        TerminalReporter.__init__(self, reporter.config)
コード例 #20
0
 def __init__(self, config, file=None):
   TerminalReporter.__init__(self, config, file)
コード例 #21
0
ファイル: pytest_litf.py プロジェクト: Gnonpi/pytest-litf
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.reports = []
     self.reportsbyid = {}
コード例 #22
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
     self.stats = STATS
コード例 #23
0
 def __init__(self, config, file=None):
     self.sqlcount = config.getvalue('sqlcount')
     if self.sqlcount and not config.option.verbose:
         config.option.verbose = 1
     TerminalReporter.__init__(self, config, file)
コード例 #24
0
 def __init__(self, config, file=None):
     TerminalReporter.__init__(self, config, file)
     self._prev_item = None
     self._showfs_path = False
コード例 #25
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
     self.stats = MultiProcessMode.STATS
コード例 #26
0
ファイル: pytest_steps.py プロジェクト: ck1981/pytest-steps
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self.config = reporter.config
     self.outdent = DEFAULT_OUTDENT
     self.stdout = os.fdopen(os.dup(sys.stdout.fileno()), 'w')
     self.tw = py._io.terminalwriter.TerminalWriter(self.stdout)
コード例 #27
0
 def __init__(self, config):
     TerminalReporter.__init__(self, config)
コード例 #28
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = self.writer = reporter.writer  # some monkeypatching needed to access existing writer
     self.stats = manager.dict()
     self.stats_lock = manager.Lock()
コード例 #29
0
 def __init__(self, config, file=None):
   TerminalReporter.__init__(self, config, file)
コード例 #30
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
コード例 #31
0
 def __init__(self, reporter):
     """ Initilize """
     # pylint: disable=protected-access
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
コード例 #32
0
    def __init__(self, reporter):
        """Initialize TerminalReporter without features we don't need.

        :type reporter: :py:class:`_pytest.terminal.TerminalReporter`
        """
        TerminalReporter.__init__(self, reporter.config)
コード例 #33
0
 def __init__(self, config):
     TerminalReporter.__init__(self, config)
コード例 #34
0
 def __init__(self, reporter):
     TerminalReporter.__init__(self, reporter.config)
     self._tw = reporter._tw
     self._sessionstarttime = reporter._sessionstarttime