示例#1
0
 def _register_server_mock(self, context, server_span):
     server_span_observer = TraceServerSpanObserver('test-service',
                                                    'test-hostname',
                                                    server_span,
                                                    NullRecorder())
     server_span.register(server_span_observer)
     self.server_span_observer = server_span_observer
示例#2
0
 def setUp(self):
     self.recorder = NullRecorder()
     self.span = Span('test-id', 'test-parent-id', 'test-span-id', None, 0,
                      'test')
     self.test_span_observer = TraceSpanObserver('test-service',
                                                 'test-hostname', self.span,
                                                 self.recorder)
示例#3
0
 def _register_local_mock(self, span):
     local_span_observer = TraceLocalSpanObserver('test-service',
                                                  'test-component',
                                                  'test-hostname', span,
                                                  NullRecorder())
     self.local_span_ids.append(span.id)
     self.local_span_observers.append(local_span_observer)
     span.register(local_span_observer)
示例#4
0
 def setUp(self):
     super(TraceServerSpanObserverTests, self).setUp()
     self.recorder = NullRecorder()
     self.mock_context = mock.Mock()
     self.span = ServerSpan("test-id", "test-parent-id", "test-span-id",
                            None, 0, "test", self.mock_context)
     self.test_server_span_observer = TraceServerSpanObserver(
         "test-service", "test-hostname", self.span, self.recorder)
示例#5
0
    def setUp(self):
        super(TraceSpanObserverTests, self).setUp()
        self.recorder = NullRecorder()
        self.mock_context = mock.Mock()

        self.span = Span('test-id', 'test-parent-id', 'test-span-id', None, 0,
                         'test', self.mock_context)
        self.test_span_observer = TraceSpanObserver('test-service',
                                                    'test-hostname', self.span,
                                                    self.recorder)
示例#6
0
 def setUp(self):
     self.recorder = NullRecorder()
     self.mock_context = mock.Mock()
     self.span = ServerSpan('test-id',
                            'test-parent-id',
                            'test-span-id',
                            None,
                            0,
                            'test',
                            self.mock_context)
示例#7
0
 def setUp(self):
     super(TraceLocalSpanObserverTests, self).setUp()
     self.recorder = NullRecorder()
     self.mock_context = mock.Mock()
     self.span = ServerSpan('test-id',
                            'test-parent-id',
                            'test-span-id',
                            None,
                            0,
                            'test',
                            self.mock_context)
示例#8
0
 def setUp(self):
     self.recorder = NullRecorder()
     self.mock_context = mock.Mock()
示例#9
0
 def setUp(self):
     super(NullRecorderTests, self).setUp()
     self.recorder = NullRecorder()
     self.mock_context = mock.Mock()
示例#10
0
 def setUp(self):
     self.recorder = NullRecorder()