From 71a2ecb6ed2b32bf139e01286705ddccdc4e73c2 Mon Sep 17 00:00:00 2001 From: changemyminds Date: Sat, 16 Mar 2024 01:32:52 +0800 Subject: [PATCH] refactor: compared the array --- .../tests/test_threading.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/instrumentation/opentelemetry-instrumentation-threading/tests/test_threading.py b/instrumentation/opentelemetry-instrumentation-threading/tests/test_threading.py index 9f73f00b34..9d4630eedc 100644 --- a/instrumentation/opentelemetry-instrumentation-threading/tests/test_threading.py +++ b/instrumentation/opentelemetry-instrumentation-threading/tests/test_threading.py @@ -75,14 +75,7 @@ def test_trace_context_propagation_in_thread_pool_with_multiple_workers( result_span_contexts = [future.result() for future in futures_list] # check result - self.assertEqual(len(result_span_contexts), max_workers) - self.assertEqual( - len(result_span_contexts), len(expected_span_contexts) - ) - for index, result_span_context in enumerate(result_span_contexts): - self.assertEqual( - result_span_context, expected_span_contexts[index] - ) + self.assertEqual(result_span_contexts, expected_span_contexts) def test_trace_context_propagation_in_thread_pool_with_single_worker(self): max_workers = 1