File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 18
18
add_breadcrumb ,
19
19
Hub ,
20
20
Scope ,
21
+ last_event_id ,
21
22
)
22
23
from sentry_sdk .integrations import (
23
24
_AUTO_ENABLING_INTEGRATIONS ,
@@ -778,3 +779,24 @@ def test_classmethod_tracing(sentry_init):
778
779
with patch_start_tracing_child () as fake_start_child :
779
780
assert instance_or_class .class_ (1 ) == (TracingTestClass , 1 )
780
781
assert fake_start_child .call_count == 1
782
+
783
+
784
+ def test_last_event_id (sentry_init ):
785
+ sentry_init ()
786
+
787
+ assert last_event_id () is None
788
+
789
+ capture_exception (ValueError ("foo" ))
790
+
791
+ assert last_event_id () is not None
792
+
793
+
794
+ def test_last_event_id_transaction (sentry_init ):
795
+ sentry_init ()
796
+
797
+ assert last_event_id () is None
798
+
799
+ with start_transaction ():
800
+ pass
801
+
802
+ assert last_event_id () is None
You can’t perform that action at this time.
0 commit comments