@Test
public void testForwarding() {
testAddHost();
// make sure mac1 can communicate with mac2
IOFMessageListener listener = getVirtualNetworkListener();
cntx = new FloodlightContext();
IFloodlightProviderService.bcStore.put(cntx,
IFloodlightProviderService.CONTEXT_PI_PAYLOAD,
(Ethernet)mac1ToMac2PacketIntestPacket);
Command ret = listener.receive(sw1, mac1ToMac2PacketIn, cntx);
assertTrue(ret == Command.CONTINUE);
// make sure mac1 can't communicate with mac4
cntx = new FloodlightContext();
IFloodlightProviderService.bcStore.put(cntx,
IFloodlightProviderService.CONTEXT_PI_PAYLOAD,
(Ethernet)mac1ToMac4PacketIntestPacket);
ret = listener.receive(sw1, mac1ToMac4PacketIn, cntx);
assertTrue(ret == Command.STOP);
}