    @Test
    public void subspan_implicitAsChildOf() {

        final String spanId = "some-span-id-" + System.currentTimeMillis();
        final Map<String, String> parentBaggage = new HashMap<>();
        parentBaggage.put(SpanBuilderR.BAGGAGE_SPANID_KEY, spanId);

        // setup mocks
        when(scopeManagerMock.activeSpan()).thenReturn(parentSpanMock);
        when(parentSpanContextMock.baggageItems()).thenReturn(parentBaggage.entrySet());

        final SpanR spanR = (SpanR) new SpanBuilderR(spanBuilderMock, reporterMock, "some-operation", scopeManagerMock).start();

        // verify
        assertFalse(spanR.references.isEmpty());
        verify(scopeManagerMock, atLeastOnce()).activeSpan();
        verify(spanBuilderMock).start();
        verify(parentSpanMock).context();
        verify(parentSpanContextMock, atLeastOnce()).baggageItems();
        assertEquals(spanId, spanR.references.get(CHILD_OF));
    }