@Test protected void getDependenciesAllInstrumented(TestInfo testInfo) throws Exception {
    String testSuffix = testSuffix(testInfo);
    String traceId = newTraceId();

    String frontend = appendSuffix(TestObjects.FRONTEND.serviceName(), testSuffix);
    String backend = appendSuffix(TestObjects.BACKEND.serviceName(), testSuffix);
    String db = appendSuffix(TestObjects.DB.serviceName(), testSuffix);

    Endpoint one = Endpoint.newBuilder().serviceName(frontend).ip("127.0.0.1").build();
    Endpoint onePort3001 = one.toBuilder().port(3001).build();
    Endpoint two = Endpoint.newBuilder().serviceName(backend).ip("127.0.0.2").build();
    Endpoint twoPort3002 = two.toBuilder().port(3002).build();
    Endpoint three = Endpoint.newBuilder().serviceName(db).ip("127.0.0.3").build();

    List<Span> trace = List.of(
      Span.newBuilder().traceId(traceId).id("10").name("get")
        .kind(Kind.SERVER)
        .timestamp(TODAY * 1000L)
        .duration(350 * 1000L)
        .localEndpoint(one)
        .build(),
      Span.newBuilder().traceId(traceId).parentId("10").id("20").name("get")
        .kind(Kind.CLIENT)
        .timestamp((TODAY + 50) * 1000L)
        .duration(250 * 1000L)
        .localEndpoint(onePort3001)
        .build(),
      Span.newBuilder().traceId(traceId).parentId("10").id("20").name("get").shared(true)
        .kind(Kind.SERVER)
        .timestamp((TODAY + 100) * 1000L)
        .duration(150 * 1000L)
        .localEndpoint(two)
        .build(),
      Span.newBuilder().traceId(traceId).parentId("20").id("30").name("query")
        .kind(Kind.CLIENT)
        .timestamp((TODAY + 150) * 1000L)
        .duration(50 * 1000L)
        .localEndpoint(twoPort3002)
        .build(),
      Span.newBuilder().traceId(traceId).parentId("20").id("30").name("query").shared(true)
        .kind(Kind.SERVER)
        .timestamp((TODAY + 160) * 1000L)
        .duration(20 * 1000L)
        .localEndpoint(three)
        .build()
    );

    processDependencies(trace);

    assertThat(store().getDependencies(endTs(trace), DAY).execute()).containsOnly(
      DependencyLink.newBuilder()
        .parent(frontend)
        .child(backend)
        .callCount(1)
        .build(),
      DependencyLink.newBuilder()
        .parent(backend)
        .child(db)
        .callCount(1)
        .build()
    );
  }
When all servers are instrumented, they all record {@link Kind#SERVER} and the {@link
Span#localEndpoint()} indicates the service.
zipkin-tests/src/main/java/zipkin2/storage/ITDependencies.java