Further rework of base schemas
[netconf.git] / netconf / sal-netconf-connector / src / test / java / org / opendaylight / netconf / sal / connect / netconf / NetconfToNotificationTest.java
index 249bf065e85048ad8ce1401e3df6c6054523b6d9..365acb668b0efd4ed06fe2297febf64ccdb162cd 100644 (file)
@@ -29,7 +29,7 @@ import org.opendaylight.yangtools.yang.model.api.Module;
 import org.opendaylight.yangtools.yang.test.util.YangParserTestUtils;
 import org.w3c.dom.Document;
 
-public class NetconfToNotificationTest {
+public class NetconfToNotificationTest extends AbstractBaseSchemasTest {
 
     NetconfMessageTransformer messageTransformer;
 
@@ -65,14 +65,16 @@ public class NetconfToNotificationTest {
     @Test(expected =  IllegalArgumentException.class)
     public void testMostRecentWrongYangModel() throws Exception {
         final EffectiveModelContext schemaContext = getNotificationSchemaContext(getClass(), true);
-        messageTransformer = new NetconfMessageTransformer(new EmptyMountPointContext(schemaContext), true);
+        messageTransformer = new NetconfMessageTransformer(new EmptyMountPointContext(schemaContext), true,
+            BASE_SCHEMAS.getBaseSchema());
         messageTransformer.toNotification(userNotification);
     }
 
     @Test
     public void testToNotificationFunction() throws Exception {
         final EffectiveModelContext schemaContext = getNotificationSchemaContext(getClass(), false);
-        messageTransformer = new NetconfMessageTransformer(new EmptyMountPointContext(schemaContext), true);
+        messageTransformer = new NetconfMessageTransformer(new EmptyMountPointContext(schemaContext), true,
+            BASE_SCHEMAS.getBaseSchema());
         final DOMNotification domNotification = messageTransformer.toNotification(userNotification);
         final ContainerNode root = domNotification.getBody();
         assertNotNull(root);