Bug 5085: Clean-up test and retest JUnit tests
[yangtools.git] / yang / yang-data-impl / src / test / java / org / opendaylight / yangtools / yang / data / impl / codecs / Int8CodecStringTest.java
similarity index 68%
rename from yang/yang-data-impl/src/test/java/org/opendaylight/yangtools/yang/data/impl/test/codecs/Int8CodecStringTest.java
rename to yang/yang-data-impl/src/test/java/org/opendaylight/yangtools/yang/data/impl/codecs/Int8CodecStringTest.java
index b699b502fd164ceef5bb4212cfee2f932d8b3530..4ee8492f194d24b4440c94fc5665ca8798775f00 100644 (file)
@@ -1,16 +1,14 @@
 /*
- * Copyright (c) 2014 Brocade Communications Systems, Inc. and others.  All rights reserved.
+ * Copyright (c) 2016 Cisco Systems, Inc. and others.  All rights reserved.
  *
  * This program and the accompanying materials are made available under the
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
 
-package org.opendaylight.yangtools.yang.data.impl.test.codecs;
+package org.opendaylight.yangtools.yang.data.impl.codecs;
 
 import static org.junit.Assert.*;
-import static org.opendaylight.yangtools.yang.data.impl.test.codecs.TypeDefinitionAwareCodecTestHelper.deserializeWithExpectedIllegalArgEx;
-import static org.opendaylight.yangtools.yang.data.impl.test.codecs.TypeDefinitionAwareCodecTestHelper.getCodec;
 
 import org.junit.Test;
 import org.opendaylight.yangtools.yang.data.api.codec.Int8Codec;
@@ -26,7 +24,7 @@ public class Int8CodecStringTest {
     @SuppressWarnings("unchecked")
     @Test
     public void testSerialize() {
-        Int8Codec<String> codec = getCodec(Int8.getInstance(), Int8Codec.class);
+        Int8Codec<String> codec = TypeDefinitionAwareCodecTestHelper.getCodec(Int8.getInstance(), Int8Codec.class);
 
         assertEquals("serialize", "10", codec.serialize(Byte.valueOf( (byte) 10 )));
         assertEquals("serialize", "", codec.serialize(null));
@@ -42,7 +40,7 @@ public class Int8CodecStringTest {
         final String integer = "64";
         final String negInteger = "-64";
 
-        Int8Codec<String> codec = getCodec(Int8.getInstance(), Int8Codec.class);
+        Int8Codec<String> codec = TypeDefinitionAwareCodecTestHelper.getCodec(Int8.getInstance(), Int8Codec.class);
 
         assertEquals("deserialize", codec.deserialize(hexa), Byte.valueOf("040", 16));
         assertEquals("deserialize", codec.deserialize(negHexa), Byte.valueOf("-040", 16));
@@ -51,8 +49,8 @@ public class Int8CodecStringTest {
         assertEquals("deserialize", codec.deserialize(integer), Byte.valueOf(integer, 10));
         assertEquals("deserialize", codec.deserialize(negInteger), Byte.valueOf(negInteger, 10));
 
-        deserializeWithExpectedIllegalArgEx(codec, "1o");
-        deserializeWithExpectedIllegalArgEx(codec, "");
-        deserializeWithExpectedIllegalArgEx(codec, null);
+        TypeDefinitionAwareCodecTestHelper.deserializeWithExpectedIllegalArgEx(codec, "1o");
+        TypeDefinitionAwareCodecTestHelper.deserializeWithExpectedIllegalArgEx(codec, "");
+        TypeDefinitionAwareCodecTestHelper.deserializeWithExpectedIllegalArgEx(codec, null);
     }
 }