public static void testVNX2NetAllocAssign(Map<URI,List<Initiator>> net2InitiatorsMapA,Map<URI,List<Initiator>> net2InitiatorsMapB,Map<URI,List<Initiator>> net2InitiatorsMapC,Map<URI,List<Initiator>> net2InitiatorsMapD,int maxPaths,int minPaths,int pathsPerInitiator,int initiatorsPerPort) throws Exception {
  Map<URI,Map<URI,List<Initiator>>> hostToNetToInitiatorsMap=new HashMap<URI,Map<URI,List<Initiator>>>();
  URI hostA=getHostURI(net2InitiatorsMapA);
  hostToNetToInitiatorsMap.put(hostA,net2InitiatorsMapA);
  if (net2InitiatorsMapB != null) {
    URI hostB=getHostURI(net2InitiatorsMapB);
    hostToNetToInitiatorsMap.put(hostB,net2InitiatorsMapB);
  }
  if (net2InitiatorsMapC != null) {
    URI hostC=getHostURI(net2InitiatorsMapC);
    hostToNetToInitiatorsMap.put(hostC,net2InitiatorsMapC);
  }
  if (net2InitiatorsMapD != null) {
    URI hostD=getHostURI(net2InitiatorsMapD);
    hostToNetToInitiatorsMap.put(hostD,net2InitiatorsMapD);
  }
  PortAllocationContext net1ctx=createVNXNet1();
  PortAllocationContext net2ctx=createVNXNet2();
  PortAllocationContext[] contexts=new PortAllocationContext[]{net1ctx,net2ctx};
  testAllocationAssignment(contexts,hostToNetToInitiatorsMap,maxPaths,minPaths,pathsPerInitiator,initiatorsPerPort,"vnxblock",null);
}

public static void testVNX2NetAllocAssign ( Map < URI , List < Initiator > > net2InitiatorsMapA , Map < URI , List < Initiator > > net2InitiatorsMapB , Map < URI , List < Initiator > > net2InitiatorsMapC , Map < URI , List < Initiator > > net2InitiatorsMapD , int maxPaths , int minPaths , int pathsPerInitiator , int initiatorsPerPort ) throws Exception { Map < URI , Map < URI , List < Initiator > > > hostToNetToInitiatorsMap = new HashMap < URI , Map < URI , List < Initiator > > > ( ) ; URI hostA = getHostURI ( net2InitiatorsMapA ) ; hostToNetToInitiatorsMap . put ( hostA , net2InitiatorsMapA ) ; if ( net2InitiatorsMapB != null ) { URI hostB = getHostURI ( net2InitiatorsMapB ) ; hostToNetToInitiatorsMap . put ( hostB , net2InitiatorsMapB ) ; } if ( net2InitiatorsMapC != null ) { URI hostC = getHostURI ( net2InitiatorsMapC ) ; hostToNetToInitiatorsMap . put ( hostC , net2InitiatorsMapC ) ; } if ( net2InitiatorsMapD != null ) { URI hostD = getHostURI ( net2InitiatorsMapD ) ; hostToNetToInitiatorsMap . put ( hostD , net2InitiatorsMapD ) ; } PortAllocationContext net1ctx = createVNXNet1 ( ) ; PortAllocationContext net2ctx = createVNXNet2 ( ) ; PortAllocationContext [ ] contexts = new PortAllocationContext [ ] { net1ctx , net2ctx } ; testAllocationAssignment ( contexts , hostToNetToInitiatorsMap , maxPaths , minPaths , pathsPerInitiator , initiatorsPerPort , "vnxblock" , null ) ; }
test allocation in a vnx two network environment .
