use of org.openkilda.floodlight.model.EffectiveIds in project open-kilda by telstra.
the class IngressCommandInstallTest method errorOnFlowMod.
@Test
public void errorOnFlowMod() {
IngressFlowSegmentBase command = makeCommand(endpointIngressSingleVlan, meterConfig, makeMetadata(false));
switchFeaturesSetup(sw, true);
expectMeterInstall();
expectMakeOuterOnlyVlanForwardMessage(command, new EffectiveIds(meterConfig.getId(), null));
expectNoMoreOfMessages();
replayAll();
CompletableFuture<FlowSegmentReport> result = command.execute(commandProcessor);
getWriteRecord(0).getFuture().completeExceptionally(new SwitchErrorResponseException(dpIdNext, of.errorMsgs().buildBadRequestErrorMsg().setCode(OFBadRequestCode.BAD_LEN).build()));
verifyErrorCompletion(result, SwitchOperationException.class);
}
use of org.openkilda.floodlight.model.EffectiveIds in project open-kilda by telstra.
the class IngressCommandInstallTest method processZeroVlanMultiTable.
protected void processZeroVlanMultiTable(IngressFlowSegmentBase command) throws Exception {
expectMakeDefaultPortForwardMessage(command, new EffectiveIds(meterConfig.getId(), null));
expectMakeCustomerPortSharedCatchInstallMessage(command);
executeCommand(command, 2);
}
use of org.openkilda.floodlight.model.EffectiveIds in project open-kilda by telstra.
the class IngressCommandInstallTest method processOneVlanMultiTable.
protected void processOneVlanMultiTable(IngressFlowSegmentBase command) throws Exception {
expectMakeSingleVlanForwardMessage(command, new EffectiveIds(meterConfig.getId(), null));
expectMakeCustomerPortSharedCatchInstallMessage(command);
expectMakeOuterVlanMatchSharedMessage(command);
executeCommand(command, 3);
}
use of org.openkilda.floodlight.model.EffectiveIds in project open-kilda by telstra.
the class IngressCommandInstallTest method processZeroVlanSingleTable.
protected void processZeroVlanSingleTable(IngressFlowSegmentBase command) throws Exception {
expectMakeDefaultPortForwardMessage(command, new EffectiveIds(meterConfig.getId(), null));
executeCommand(command, 1);
}
use of org.openkilda.floodlight.model.EffectiveIds in project open-kilda by telstra.
the class IngressCommandInstallTest method errorNoMeterSupport.
@Test
public void errorNoMeterSupport() throws Exception {
switchFeaturesSetup(sw, false);
IngressFlowSegmentBase command = makeCommand(endpointIngressSingleVlan, meterConfig, makeMetadata());
expectMeterInstall(new UnsupportedSwitchOperationException(dpIdNext, "Switch doesn't support meters (unit-test)"));
expectMakeOuterOnlyVlanForwardMessage(command, new EffectiveIds());
expectNoMoreOfMessages();
replayAll();
CompletableFuture<FlowSegmentReport> result = command.execute(commandProcessor);
verifyWriteCount(1);
verifySuccessCompletion(result);
verifyNoMeterCall((OFFlowAdd) getWriteRecord(0).getRequest());
}
Aggregations