Remove unused imports
[openflowplugin.git] / extension / openflowplugin-extension-nicira / src / test / java / org / opendaylight / openflowplugin / extension / vendor / nicira / convertor / match / test / TunIpv4SrcConverterTest.java
1 package org.opendaylight.openflowplugin.extension.vendor.nicira.convertor.match.test;
2
3 import static org.junit.Assert.assertEquals;
4 import org.junit.Test;
5 import org.opendaylight.openflowplugin.extension.vendor.nicira.convertor.match.TunIPv4SrcConvertor;
6 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.Ipv4Address;
7
8 public class TunIpv4SrcConverterTest {
9
10     private static final Ipv4Address IPV4_ADDRESS = new Ipv4Address("1.2.3.4");
11     private static final Long IPV4_LONG = new Long(16909060L);
12
13     @Test
14     public void testIpv4toLong() {
15         TunIPv4SrcConvertor converter = new TunIPv4SrcConvertor();
16         Long result = converter.ipv4ToLong(IPV4_ADDRESS);
17         assertEquals("Does not match",IPV4_LONG,result);
18     }
19
20     @Test
21     public void testLongtoIpv4() {
22         TunIPv4SrcConvertor converter = new TunIPv4SrcConvertor();
23         Ipv4Address result = converter.longToIpv4Address(16909060L);
24         assertEquals("Does not match",IPV4_ADDRESS,result);
25     }
26
27 }