Make AbstractDataBrokerTestCustomizer#getDomBroker public 89/73389/1
authorTom Pantelis <tompantelis@gmail.com>
Mon, 25 Jun 2018 03:12:08 +0000 (23:12 -0400)
committerTom Pantelis <tompantelis@gmail.com>
Mon, 25 Jun 2018 03:12:08 +0000 (23:12 -0400)
The DOMDataBroker is exposed via createDOMDataBroker however
this creates a new instance so users don't actually get the
DOMDataBroker instance that is backing the DataBroker.
Therefore expose getDomBroker publicly.

Change-Id: Id4b53935e4c17e4a9cd4538d669a9e05d97892af
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/md/sal/binding/test/AbstractBaseDataBrokerTest.java
opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/md/sal/binding/test/AbstractDataBrokerTestCustomizer.java

index cbbfc12edb45dfb5c36f636287c0960fa59a5e55..408d8c15466002c53893bcdc7d57f7bc5e6a5624 100644 (file)
@@ -36,7 +36,7 @@ public abstract class AbstractBaseDataBrokerTest extends AbstractSchemaAwareTest
     protected void setupWithSchema(final SchemaContext context) {
         testCustomizer = createDataBrokerTestCustomizer();
         dataBroker = testCustomizer.createDataBroker();
-        domBroker = testCustomizer.createDOMDataBroker();
+        domBroker = testCustomizer.getDOMDataBroker();
         testCustomizer.updateSchema(context);
     }
 
index 784fea804b2e6b671875ea99a2bba5419834381f..f36b685435d0090d0e0dcb2172ecb60e3afec70b 100644 (file)
@@ -102,7 +102,7 @@ public abstract class AbstractDataBrokerTestCustomizer {
         return this.schemaService;
     }
 
-    private DOMDataBroker getDOMDataBroker() {
+    public DOMDataBroker getDOMDataBroker() {
         if (this.domDataBroker == null) {
             this.domDataBroker = createDOMDataBroker();
         }