Skip to content

Commit 0d9a221

Browse files
committed
better readability
1 parent 664f0e0 commit 0d9a221

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

tests/integrations/threading/test_threading.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -176,22 +176,22 @@ def target():
176176

177177
def test_scope_data_not_leaked_in_threads(sentry_init):
178178
sentry_init(
179-
traces_sample_rate=1.0,
180-
integrations=[ThreadingIntegration(propagate_hub=True)],
179+
integrations=[ThreadingIntegration()],
181180
)
182181

182+
sentry_sdk.set_tag("initial_tag", "initial_value")
183183
initial_iso_scope = sentry_sdk.get_isolation_scope()
184184

185185
def do_some_work(number):
186186
# change data in isolation scope in thread
187-
sentry_sdk.set_tag("foo", "bar")
187+
sentry_sdk.set_tag("thread_tag", "thread_value")
188188

189189
with futures.ThreadPoolExecutor(max_workers=2) as executor:
190190
all_futures = []
191191
for number in range(10):
192192
all_futures.append(executor.submit(do_some_work, number))
193193
futures.wait(all_futures)
194194

195-
assert (
196-
initial_iso_scope._tags == {}
197-
), "The isolation scope in the main thread should not be modified by the started threads."
195+
assert initial_iso_scope._tags == {
196+
"initial_tag": "initial_value"
197+
}, "The isolation scope in the main thread should not be modified by the started threads."

0 commit comments

Comments
 (0)