use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.pcep.sync.optimizations.rev171025.Stateful1 in project bgpcep by opendaylight.
the class PCCMockCommon method checkSynchronizedSession.
static void checkSynchronizedSession(final int numberOfLsp, final TestingSessionListener pceSessionListener, final BigInteger expectedeInitialDb) throws Exception {
assertTrue(pceSessionListener.isUp());
// Send Open with LspDBV = 1
final int numberOfSyncMessage = 1;
int numberOfLspExpected = numberOfLsp;
if (!expectedeInitialDb.equals(BigInteger.ZERO)) {
checkEquals(() -> checkSequequenceDBVersionSync(pceSessionListener, expectedeInitialDb));
numberOfLspExpected += numberOfSyncMessage;
}
checkReceivedMessages(pceSessionListener, numberOfLspExpected);
final PCEPSession session = pceSessionListener.getSession();
checkSession(session, DEAD_TIMER, KEEP_ALIVE);
assertTrue(session.getRemoteTlvs().getAugmentation(Tlvs1.class).getStateful().getAugmentation(Stateful1.class).isInitiation());
assertNull(session.getLocalTlvs().getAugmentation(Tlvs3.class).getLspDbVersion().getLspDbVersionValue());
}
Aggregations