コード例 #1
0
ファイル: resultchannel.py プロジェクト: mlyko/tadek-ui
 def __init__(self, name, result, **params):
     '''
     Initializes the channel and ties it with provided ResultChannelHelper
     instance.
     '''
     TestResultChannel.__init__(self, name, **params)
     self._result = result
コード例 #2
0
ファイル: consolechannel.py プロジェクト: mlyko/tadek-ui
 def stopTest(self, result, device):
     """
     Signals stop of execution of a test.
     """
     TestResultChannel.stopTest(self, result, device)
     if self.isEnabled():
         self._console.stopTest(result, device)
コード例 #3
0
ファイル: progresschannel.py プロジェクト: mlyko/tadek-ui
 def __init__(self, name, progress, **params):
     '''
     Initializes the channel and ties it with provided ProgressChannelHelper
     instance.
     '''
     TestResultChannel.__init__(self, name, **params)
     self._progress = progress
コード例 #4
0
 def __init__(self, name, progress, **params):
     '''
     Initializes the channel and ties it with provided ProgressChannelHelper
     instance.
     '''
     TestResultChannel.__init__(self, name, **params)
     self._progress = progress
コード例 #5
0
ファイル: consolechannel.py プロジェクト: mlyko/tadek-ui
 def start(self, result):
     """
     Signals start of execution of tests.
     """
     TestResultChannel.start(self, result)
     if self.isEnabled():
         self._console.start(result)
コード例 #6
0
 def __init__(self, name, result, **params):
     '''
     Initializes the channel and ties it with provided ResultChannelHelper
     instance.
     '''
     TestResultChannel.__init__(self, name, **params)
     self._result = result
コード例 #7
0
ファイル: summarychannel.py プロジェクト: mlyko/tadek-common
 def startTest(self, result, device):
     '''
     Processes a test start execution for the summary channel.
     '''
     TestResultChannel.startTest(self, result, device)
     if isinstance(result, TestCaseResult):
         self._counters[STATUS_NOT_COMPLETED] += 1
         self._counters[COUNTER_TESTS_RUN] += 1
コード例 #8
0
 def startTest(self, result, device):
     '''
     Processes a test start execution for the summary channel.
     '''
     TestResultChannel.startTest(self, result, device)
     if isinstance(result, TestCaseResult):
         self._counters[STATUS_NOT_COMPLETED] += 1
         self._counters[COUNTER_TESTS_RUN] += 1
コード例 #9
0
 def startTest(self, result, device):
     '''
     Processes a test start execution for the stream channel.
     '''
     TestResultChannel.startTest(self, result, device)
     formatters = (self._verboseFormats if self.isVerbose()
                                        else self._simpleFormats)
     self.write(self._format(result, formatters["start"], formatters,
                             self._deviceAttrs(device)))
     self.write(self._formatResult(result, formatters,
                                   self._deviceAttrs(device)))
コード例 #10
0
ファイル: summarychannel.py プロジェクト: mlyko/tadek-common
 def stopTest(self, result, device):
     '''
     Processes a test stop execution for the summary channel.
     '''
     TestResultChannel.stopTest(self, result, device)
     if isinstance(result, TestCaseResult):
         self._counters[STATUS_NOT_COMPLETED] -= 1
         self._counters[device.status] += 1
         self._counters[_STOP_STAMP] = time.time()
     if device.cores:
         self._counters[COUNTER_CORE_DUMPS] += len(device.cores)
コード例 #11
0
 def stopTest(self, result, device):
     '''
     Processes a test stop execution for the summary channel.
     '''
     TestResultChannel.stopTest(self, result, device)
     if isinstance(result, TestCaseResult):
         self._counters[STATUS_NOT_COMPLETED] -= 1
         self._counters[device.status] += 1
         self._counters[_STOP_STAMP] = time.time()
     if device.cores:
         self._counters[COUNTER_CORE_DUMPS] += len(device.cores)
コード例 #12
0
 def stopTest(self, result, device):
     '''
     Processes a test stop execution for the stream channel.
     '''
     TestResultChannel.stopTest(self, result, device)
     formatters = (self._verboseFormats if self.isVerbose()
                                        else self._simpleFormats)
     self.write(self._format(result, formatters["stop"], formatters,
                             self._deviceAttrs(device)))
     self.write(self._formatResult(result, formatters,
                                   self._deviceAttrs(device)))
     self.write(self._format(device.cores, formatters["cores"],
                             formatters, self._basicAttrs(device)))
     self.write(self._format(device.errors, formatters["errors"],
                             formatters, self._basicAttrs(device)))
コード例 #13
0
ファイル: summarychannel.py プロジェクト: mlyko/tadek-common
 def start(self, result):
     '''
     Initializes all the channel counters.
     '''
     TestResultChannel.start(self, result)
     stamp = time.time()
     self._counters = {
         _START_STAMP: stamp,
         _STOP_STAMP: stamp,
         COUNTER_N_TESTS: _countCaseResults(result),
         COUNTER_TESTS_RUN: 0,
         COUNTER_CORE_DUMPS: 0
     }
     for status in STATUS_COUNTERS:
         self._counters[status] = 0
コード例 #14
0
 def start(self, result):
     '''
     Initializes all the channel counters.
     '''
     TestResultChannel.start(self, result)
     stamp = time.time()
     self._counters = {
         _START_STAMP: stamp,
         _STOP_STAMP: stamp,
         COUNTER_N_TESTS: _countCaseResults(result),
         COUNTER_TESTS_RUN: 0,
         COUNTER_CORE_DUMPS: 0
     }
     for status in STATUS_COUNTERS:
         self._counters[status] = 0
コード例 #15
0
 def startTest(self, result, device):
     '''
     Signals start of execution of a test.
     '''
     TestResultChannel.startTest(self, result, device)
     self._progress.startTest(result, device)
コード例 #16
0
 def __init__(self, name, stream=None, encoding=None, **params):
     TestResultChannel.__init__(self, name, **params)
     self._stream = stream or sys.stderr
     self._encoding = encoding or getattr(self._stream, "encoding", None)
コード例 #17
0
 def stopTest(self, result, device):
     '''
     Signals stop of execution of a test.
     '''
     TestResultChannel.stopTest(self, result, device)
     self._result.stopTest(result, device)
コード例 #18
0
ファイル: resultchannel.py プロジェクト: mlyko/tadek-ui
 def stop(self):
     '''
     Signals stop of execution of tests.
     '''
     TestResultChannel.stop(self)
     self._result.stop()
コード例 #19
0
ファイル: resultchannel.py プロジェクト: mlyko/tadek-ui
 def stopTest(self, result, device):
     '''
     Signals stop of execution of a test.
     '''
     TestResultChannel.stopTest(self, result, device)
     self._result.stopTest(result, device)
コード例 #20
0
 def __init__(self, name, enabled=True, verbose=False, **params):
     TestResultChannel.__init__(self, name, enabled, verbose, **params)
     self._counters = {}
コード例 #21
0
ファイル: summarychannel.py プロジェクト: mlyko/tadek-common
 def __init__(self, name, enabled=True, verbose=False, **params):
     TestResultChannel.__init__(self, name, enabled, verbose, **params)
     self._counters = {}
コード例 #22
0
ファイル: progresschannel.py プロジェクト: mlyko/tadek-ui
 def startTest(self, result, device):
     '''
     Signals start of execution of a test.
     '''
     TestResultChannel.startTest(self, result, device)
     self._progress.startTest(result, device)
コード例 #23
0
ファイル: consolechannel.py プロジェクト: mlyko/tadek-ui
 def __init__(self, name, console, **params):
     TestResultChannel.__init__(self, name, **params)
     self._console = console
コード例 #24
0
 def stop(self):
     '''
     Signals stop of execution of tests.
     '''
     TestResultChannel.stop(self)
     self._result.stop()
コード例 #25
0
 def start(self, result):
     '''
     Signals start of execution of tests.
     '''
     TestResultChannel.start(self, result)
     self._result.start(result)
コード例 #26
0
ファイル: resultchannel.py プロジェクト: mlyko/tadek-ui
 def start(self, result):
     '''
     Signals start of execution of tests.
     '''
     TestResultChannel.start(self, result)
     self._result.start(result)