Remove explicit UOE throws
[mdsal.git] / binding / mdsal-binding-spec-util / src / test / java / org / opendaylight / mdsal / binding / spec / naming / BindingMappingTest.java
index 39742ec7edb0cd0edb5d40630cbdf9be0a2a3d7d..d2dd726966c43c0fcf79da430032961d0f0716be 100644 (file)
@@ -9,12 +9,8 @@ package org.opendaylight.mdsal.binding.spec.naming;
 
 import static com.google.common.collect.ImmutableList.of;
 import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
 
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
 import java.net.URI;
 import java.util.HashMap;
 import java.util.List;
@@ -45,21 +41,6 @@ public class BindingMappingTest {
         assertEquals("", BindingMapping.getClassName(""));
     }
 
-    @Test(expected = UnsupportedOperationException.class)
-    @SuppressWarnings({ "checkstyle:illegalThrows", "checkstyle:avoidHidingCauseException" })
-    public void privateConstructTest() throws Throwable {
-        final Constructor<BindingMapping> bindingMappingConstructor = BindingMapping.class.getDeclaredConstructor();
-        assertFalse(bindingMappingConstructor.isAccessible());
-
-        bindingMappingConstructor.setAccessible(true);
-        try {
-            bindingMappingConstructor.newInstance();
-            fail("Expected exception for calling private constructor");
-        } catch (InvocationTargetException e) {
-            throw e.getCause();
-        }
-    }
-
     @Test
     public void mapEnumAssignedNamesTest() {
         // Okay identifier