-
-
Notifications
You must be signed in to change notification settings - Fork 464
Closed
Description
A unit test on sentry-core to test the scope isolation on non-global hub mode:
pseudo code;
Sentry.init
Sentry.configureScope(s -> s.setTag("a", "a");
var e = new Semaphore(count: 2);
var s = new Semaphore(count: 2);
new Thread(() -> {
Sentry.configureScope(s -> s.setTag("b", "b");
e.set();
s.wait();
Sentry.configureScope(s -> assert(s.getTags(), 2); // make sure 'a' and 'b' are here
}
new Thread(() -> {
Sentry.configureScope(s -> s.setTag("c", "c");
e.set();
s.wait();
Sentry.configureScope(s -> assert(s.getTags(), 3); // make sure 'a', 'b' and 'c' are here
}
e.wait();
s.set();
Sentry.configureScope(s -> assert(s.getTags(), 1); // make sure 'a' only is here
Metadata
Metadata
Assignees
Labels
No labels