Skip to content

Commit adf5915

Browse files
author
Emanuele Palazzetti
committed
[tornado] removing delayed test because it is not a real use case
1 parent e231147 commit adf5915

File tree

1 file changed

+0
-37
lines changed

1 file changed

+0
-37
lines changed

tests/contrib/tornado/test_executor_decorator.py

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -73,43 +73,6 @@ def test_on_executor_submit(self):
7373
eq_(0, executor_span.error)
7474
ok_(executor_span.duration >= 0.05)
7575

76-
# def test_on_delayed_executor_handler(self):
77-
# # it should trace a handler that uses @run_on_executor but that doesn't
78-
# # wait for its termination
79-
# response = self.fetch('/executor_delayed_handler/')
80-
# eq_(200, response.code)
81-
#
82-
# # timeout for the background thread execution
83-
# time.sleep(0.1)
84-
#
85-
# traces = self.tracer.writer.pop_traces()
86-
# eq_(2, len(traces))
87-
# eq_(1, len(traces[0]))
88-
# eq_(1, len(traces[1]))
89-
#
90-
# # order the `traces` list to have deterministic results
91-
# # (required only for this special use case)
92-
# traces.sort(key=lambda x: x[0].name, reverse=True)
93-
#
94-
# # this trace yields the execution of the thread
95-
# request_span = traces[0][0]
96-
# eq_('tornado-web', request_span.service)
97-
# eq_('tornado.request', request_span.name)
98-
# eq_('http', request_span.span_type)
99-
# eq_('tests.contrib.tornado.web.app.ExecutorDelayedHandler', request_span.resource)
100-
# eq_('GET', request_span.get_tag('http.method'))
101-
# eq_('200', request_span.get_tag('http.status_code'))
102-
# eq_('/executor_delayed_handler/', request_span.get_tag('http.url'))
103-
# eq_(0, request_span.error)
104-
#
105-
# # this trace is executed in a different thread
106-
# executor_span = traces[1][0]
107-
# eq_('tornado-web', executor_span.service)
108-
# eq_('tornado.executor.with', executor_span.name)
109-
# eq_(executor_span.parent_id, request_span.span_id)
110-
# eq_(0, executor_span.error)
111-
# ok_(executor_span.duration >= 0.05)
112-
11376
def test_on_executor_exception_handler(self):
11477
# it should trace a handler that uses @run_on_executor
11578
response = self.fetch('/executor_exception/')

0 commit comments

Comments
 (0)