@Test public void startScopedSpan() {

  ScopedSpan scoped = tracer.startScopedSpan("foo");
  try {
    assertThat(tracer.currentTraceContext.get()).isSameAs(scoped.context());
  } finally {
    scoped.finish();
  }
  assertThat(spans.get(0).name())
    .isEqualTo("foo");
  assertThat(spans.get(0).finishTimestamp())
    .isPositive();
}