NullScope extends TraceScope { NullScope(Tracer tracer) { super(tracer, null, null); } NullScope(Tracer tracer); @Override SpanId getSpanId(); @Override void detach(); @Override void reattach(); @Override void close(); @Override String toString(); @Override void addKVAnnotation(String key, String value); @Override void addTimelineAnnotation(String msg);  }
@Test public void testNullScope() { Tracer tracer = new Tracer.Builder(). name("testNullScope"). tracerPool(new TracerPool("testNullScope")). conf(HTraceConfiguration.EMPTY). build(); verifyNullScope(tracer.newScope("testNullScope")); verifyNullScope(tracer.newNullScope()); }