Skip to content

Commit

Permalink
Update test_wsgi_middleware.py
Browse files Browse the repository at this point in the history
  • Loading branch information
lzchen committed Jul 22, 2024
1 parent cf1ec9e commit 9f0ae9a
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -231,20 +231,18 @@ def validate_response(

self.assertEqual(self.status, "200 OK")
self.assertEqual(self.response_headers, expected_headers)
expected_attributes = {}
if error:
self.assertIs(self.exc_info[0], error)
self.assertIsInstance(self.exc_info[1], error)
self.assertIsNotNone(self.exc_info[2])
if new_sem_conv:
expected_attributes[ERROR_TYPE] = error
else:
self.assertIsNone(self.exc_info)

span_list = self.memory_exporter.get_finished_spans()
self.assertEqual(len(span_list), 1)
self.assertEqual(span_list[0].name, span_name)
self.assertEqual(span_list[0].kind, trace_api.SpanKind.SERVER)
expected_attributes = {}
expected_attributes_old = {
SpanAttributes.HTTP_SERVER_NAME: "127.0.0.1",
SpanAttributes.HTTP_SCHEME: "http",
Expand Down

0 comments on commit 9f0ae9a

Please sign in to comment.