1 /* Copyright (C)2013 Pantheon Technologies, s.r.o. All rights reserved. */
\r
2 package org.opendaylight.openflowjava.protocol.impl.deserialization.factories;
\r
4 import io.netty.buffer.ByteBuf;
\r
6 import org.junit.Test;
\r
7 import org.opendaylight.openflowjava.protocol.impl.util.BufferHelper;
\r
8 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.HelloMessage;
\r
11 * @author michal.polkorab
\r
14 public class HelloMessageFactoryTest {
\r
16 /** Number of currently supported version / codec */
\r
17 public static final Short VERSION_YET_SUPPORTED = 0x04;
\r
20 * Testing {@link HelloMessageFactory} for correct translation into POJO
\r
23 public void test() {
\r
24 ByteBuf bb = BufferHelper.buildBuffer();
\r
25 HelloMessage builtByFactory = BufferHelper.decodeV13(
\r
26 HelloMessageFactory.getInstance(), bb);
\r
28 BufferHelper.checkHeaderV13(builtByFactory);
\r