IidFactory { public static InstanceIdentifier<Topology> getFlowTopologyII() { final TopologyKey key = new TopologyKey(new TopologyId("flow:1")); return InstanceIdentifier .create(NetworkTopology.class) .child(Topology.class, key); }  static InstanceIdentifier<Node> getNodeWildII(); static InstanceIdentifier<Node> getNodeII(final InstanceIdentifier<?> ii); static NodeRef createNodeRef(InstanceIdentifier<?> path); static NodeId getNodeId(InstanceIdentifier<?> path); static InstanceIdentifier<Link> getLinkWildII(); static InstanceIdentifier<Link> getLinkII(final InstanceIdentifier<?> path); static InstanceIdentifier<Topology> getFlowTopologyII();  }
@Test public void testGetTopologyLinkInstanceIdentifier() throws Exception { InstanceIdentifierBuilder<NetworkTopology> iidNetTopo = mock(InstanceIdentifierBuilder.class); InstanceIdentifierBuilder<Topology> iidTopo = mock(InstanceIdentifierBuilder.class); when(iidNetTopo.child(eq(Topology.class), any(TopologyKey.class))).thenReturn(iidTopo); assertTrue(IidFactory.getFlowTopologyII() instanceof InstanceIdentifier); }