Search in sources :

Example 1 with GetMeterStatisticsInputBuilder

use of org.opendaylight.yang.gen.v1.urn.opendaylight.meter.statistics.rev131111.GetMeterStatisticsInputBuilder in project openflowplugin by opendaylight.

the class OpendaylightMeterStatisticsServiceImplTest method testGetMeterStatistics.

@Test
public void testGetMeterStatistics() throws Exception {
    GetMeterStatisticsInputBuilder input = new GetMeterStatisticsInputBuilder().setNode(createNodeRef("unitProt:123")).setMeterId(new MeterId(21L));
    rpcResult = buildMeterStatisticsReply();
    final Future<RpcResult<GetMeterStatisticsOutput>> resultFuture = meterStatisticsService.getMeterStatistics(input.build());
    Assert.assertTrue(resultFuture.isDone());
    final RpcResult<GetMeterStatisticsOutput> rpcResult = resultFuture.get();
    Assert.assertTrue(rpcResult.isSuccessful());
    Assert.assertEquals(MultipartType.OFPMPMETER, requestInput.getValue().getType());
}
Also used : GetMeterStatisticsOutput(org.opendaylight.yang.gen.v1.urn.opendaylight.meter.statistics.rev131111.GetMeterStatisticsOutput) RpcResult(org.opendaylight.yangtools.yang.common.RpcResult) GetMeterStatisticsInputBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.meter.statistics.rev131111.GetMeterStatisticsInputBuilder) MeterId(org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterId) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)1 GetMeterStatisticsInputBuilder (org.opendaylight.yang.gen.v1.urn.opendaylight.meter.statistics.rev131111.GetMeterStatisticsInputBuilder)1 GetMeterStatisticsOutput (org.opendaylight.yang.gen.v1.urn.opendaylight.meter.statistics.rev131111.GetMeterStatisticsOutput)1 MeterId (org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterId)1 RpcResult (org.opendaylight.yangtools.yang.common.RpcResult)1