+ @Test
+ public void testConfigNetconfUnionTypes() throws Exception {
+
+ createModule(INSTANCE_NAME);
+
+ edit("netconfMessages/editConfig.xml");
+ commit();
+ Element response = getConfigRunning();
+ String trimmedResponse = XmlUtil.toString(response).replaceAll("\\s", "");
+ assertContainsString(trimmedResponse, "<ipxmlns=\"urn:opendaylight:params:xml:ns:yang:controller:test:impl\">0:0:0:0:0:0:0:1</ip>");
+ assertContainsString(trimmedResponse, "<union-test-attrxmlns=\"urn:opendaylight:params:xml:ns:yang:controller:test:impl\">456</union-test-attr>");
+
+
+ edit("netconfMessages/editConfig_setUnions.xml");
+ commit();
+ response = getConfigRunning();
+
+ trimmedResponse = XmlUtil.toString(response).replaceAll("\\s", "");
+ assertContainsString(trimmedResponse, "<ipxmlns=\"urn:opendaylight:params:xml:ns:yang:controller:test:impl\">127.1.2.3</ip>");
+ assertContainsString(trimmedResponse, "<union-test-attrxmlns=\"urn:opendaylight:params:xml:ns:yang:controller:test:impl\">randomStringForUnion</union-test-attr>");
+
+ }
+