use of org.opendaylight.genius.mdsalutil.ActionInfo in project genius by opendaylight.
the class ActionLoadIpToSpaTest method generateAction.
@Test
public void generateAction() {
ActionInfo actionInfo = new ActionLoadIpToSpa(IP_ADDRESS);
assertEquals("new ActionLoadIpToSpa(0, \"" + IP_ADDRESS + "\")", generator.getExpression(actionInfo));
}
use of org.opendaylight.genius.mdsalutil.ActionInfo in project genius by opendaylight.
the class ActionLoadMacToShaTest method generateAction.
@Test
public void generateAction() {
ActionInfo actionInfo = new ActionLoadMacToSha(new MacAddress(MAC_ADDRESS));
assertEquals("new ActionLoadMacToSha(0, new MacAddress(\"" + MAC_ADDRESS + "\"))", generator.getExpression(actionInfo));
}
use of org.opendaylight.genius.mdsalutil.ActionInfo in project genius by opendaylight.
the class ActionMoveSourceDestinationIpv6Test method generateAction.
@Test
public void generateAction() {
ActionInfo actionInfo = new ActionMoveSourceDestinationIpv6();
assertEquals("new ActionMoveSourceDestinationIpv6", generator.getExpression(actionInfo));
}
use of org.opendaylight.genius.mdsalutil.ActionInfo in project genius by opendaylight.
the class ActionNxLoadInPortTest method generateAction.
@Test
public void generateAction() {
ActionInfo actionInfo = new ActionNxLoadInPort(VALUE);
assertEquals("new ActionNxLoadInPort(0, " + VALUE + "bi)", generator.getExpression(actionInfo));
}
use of org.opendaylight.genius.mdsalutil.ActionInfo in project genius by opendaylight.
the class ActionInfoBuilderTest method learnActionValuesMatrix.
@Test
@Ignore("Needs to be rewritten")
public void learnActionValuesMatrix() {
ActionInfo actionInfo = new ActionLearn(1, 2, 3, BigInteger.valueOf(4), 5, (short) 6, 7, 8, Arrays.asList(new ActionLearn.CopyFromValue(2, 3, 4), new ActionLearn.OutputToPort(4, 5)));
assertEquals("(new ActionInfoBuilder => [" + System.lineSeparator() + " actionType = ActionType.learn" + System.lineSeparator() + " actionValues = #[" + System.lineSeparator() + " \"1\"," + System.lineSeparator() + " \"2\"," + System.lineSeparator() + " \"3\"," + System.lineSeparator() + " \"4\"," + System.lineSeparator() + " \"5\"," + System.lineSeparator() + " \"6\"," + System.lineSeparator() + " \"7\"," + System.lineSeparator() + " \"8\"" + System.lineSeparator() + " ]" + System.lineSeparator() + " actionValuesMatrix = #[" + System.lineSeparator() + " #[" + System.lineSeparator() + " \"COPY_FROM_VALUE\"," + System.lineSeparator() + " \"2\"," + System.lineSeparator() + " \"3\"," + System.lineSeparator() + " \"4\"" + System.lineSeparator() + " ]," + System.lineSeparator() + " #[" + System.lineSeparator() + " \"OUTPUT_TO_PORT\"," + System.lineSeparator() + " \"4\"," + System.lineSeparator() + " \"5\"" + System.lineSeparator() + " ]" + System.lineSeparator() + " ]" + System.lineSeparator() + "]).build()", generator.getExpression(actionInfo));
}
Aggregations