// Path: src/main/java/com/spotify/trickle/Trickle.java
// public static <R> ConfigurableGraph<R> call(Func0<R> func) {
//   return new GraphBuilder<R>(func);
// }


import com.google.common.util.concurrent.ListenableFuture;
import org.junit.Before;
import org.junit.Test;
import static com.google.common.util.concurrent.Futures.immediateFuture;
import static com.spotify.trickle.Trickle.call;
import static org.hamcrest.CoreMatchers.equalTo;
import static org.junit.Assert.assertThat;
  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeInTwoSubgraphs() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func1).with(root);
    Graph<String> g2 = call(func1).with(root);

    NodeInfo info1 = g1.arguments().iterator().next();
    NodeInfo info2 = g2.arguments().iterator().next();

    assertThat(info1, equalTo(info2));
  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeBoundAndNotBound() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func1).with(root);
    Graph<String> g2 = g1.bind(input, "input value");

    NodeInfo info1 = g1.arguments().iterator().next();
    NodeInfo info2 = g2.arguments().iterator().next();

    assertThat(info1, equalTo(info2));
  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeInTwoSubgraphsPredecessors() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func0).after(root);
// Path: src/main/java/com/spotify/trickle/Trickle.java
// public static <R> ConfigurableGraph<R> call(Func0<R> func) {
//   return new GraphBuilder<R>(func);
// }


// Path: src/test/java/com/spotify/trickle/TrickleIntrospectionTest.java
import com.google.common.util.concurrent.ListenableFuture;
import org.junit.Before;
import org.junit.Test;
import static com.google.common.util.concurrent.Futures.immediateFuture;
import static com.spotify.trickle.Trickle.call;
import static org.hamcrest.CoreMatchers.equalTo;
import static org.junit.Assert.assertThat;

  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeInTwoSubgraphs() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func1).with(root);
    Graph<String> g2 = call(func1).with(root);

    NodeInfo info1 = g1.arguments().iterator().next();
    NodeInfo info2 = g2.arguments().iterator().next();

    assertThat(info1, equalTo(info2));
  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeBoundAndNotBound() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func1).with(root);
    Graph<String> g2 = g1.bind(input, "input value");

    NodeInfo info1 = g1.arguments().iterator().next();
    NodeInfo info2 = g2.arguments().iterator().next();

    assertThat(info1, equalTo(info2));
  }

  @Test
  public void shouldReturnEqualNodeInfosForSameNodeInTwoSubgraphsPredecessors() throws Exception {
    Graph<String> root = call(func1).with(input);
    Graph<String> g1 = call(func0).after(root);
    Graph<String> g2 = call(func0).after(root);