We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 28dc62b commit b80d612Copy full SHA for b80d612
opentelemetry-sdk/src/trace/span.rs
@@ -1143,15 +1143,13 @@ mod tests {
1143
}
1144
1145
#[test]
1146
- #[should_panic]
1147
fn test_finished_span_consume_twice() {
1148
#[derive(Debug)]
1149
struct TestSpanProcessor;
1150
impl SpanProcessor for TestSpanProcessor {
1151
fn on_end(&self, span: &mut FinishedSpan) {
1152
let _ = span.consume();
1153
- // consume again to trigger panic
1154
- let _ = span.consume();
+ assert!(span.try_consume().is_none());
1155
1156
1157
fn on_start(&self, _span: &mut Span, _cx: &opentelemetry::Context) {}
0 commit comments