From 9b829443ebf53885730c3786287568742c33582e Mon Sep 17 00:00:00 2001 From: ToineSiebelink Date: Mon, 8 May 2023 17:07:54 +0100 Subject: Move integration test (DataService) - dropped ri module coverage to alow for move - removed performance tests (already better tests in intergration module) - added 'save' iue cases in new integration-test - removed no longer used version for save single data node (todo: remove old tests for similar functionality, will wait until new test cover same) Issue-ID: CPS-1687 Signed-off-by: ToineSiebelink Change-Id: I4c2e788e0a313938a923cd1e7e52584d739ec6f4 --- cps-ri/pom.xml | 3 ++- .../java/org/onap/cps/spi/impl/CpsDataPersistenceServiceImpl.java | 7 ------- .../cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy | 2 +- 3 files changed, 3 insertions(+), 9 deletions(-) mode change 100755 => 100644 cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy (limited to 'cps-ri') diff --git a/cps-ri/pom.xml b/cps-ri/pom.xml index 3162aa89a..3ef57cf03 100644 --- a/cps-ri/pom.xml +++ b/cps-ri/pom.xml @@ -33,7 +33,8 @@ cps-ri - 0.79 + 0.45 + diff --git a/cps-ri/src/main/java/org/onap/cps/spi/impl/CpsDataPersistenceServiceImpl.java b/cps-ri/src/main/java/org/onap/cps/spi/impl/CpsDataPersistenceServiceImpl.java index 3d2b87d7d..d0154e116 100644 --- a/cps-ri/src/main/java/org/onap/cps/spi/impl/CpsDataPersistenceServiceImpl.java +++ b/cps-ri/src/main/java/org/onap/cps/spi/impl/CpsDataPersistenceServiceImpl.java @@ -86,13 +86,6 @@ public class CpsDataPersistenceServiceImpl implements CpsDataPersistenceService private static final String QUERY_ACROSS_ANCHORS = null; private static final AnchorEntity ALL_ANCHORS = null; - @Override - public void addChildDataNode(final String dataspaceName, final String anchorName, final String parentNodeXpath, - final DataNode newChildDataNode) { - final AnchorEntity anchorEntity = getAnchorEntity(dataspaceName, anchorName); - addNewChildDataNode(anchorEntity, parentNodeXpath, newChildDataNode); - } - @Override public void addChildDataNodes(final String dataspaceName, final String anchorName, final String parentNodeXpath, final Collection dataNodes) { diff --git a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy old mode 100755 new mode 100644 index 080e34828..6d6dfd270 --- a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy +++ b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceIntegrationSpec.groovy @@ -562,7 +562,7 @@ class CpsDataPersistenceServiceIntegrationSpec extends CpsPersistenceSpecBase { given: 'a data nodes with list-element child with "/" in index value (and grandchild)' def grandChild = new DataNodeBuilder().withXpath(deleteTestGrandChildXPath).build() def child = new DataNodeBuilder().withXpath(deleteTestChildXpath).withChildDataNodes([grandChild]).build() - objectUnderTest.addChildDataNode(DATASPACE_NAME, ANCHOR_NAME3, deleteTestParentXPath, child) + objectUnderTest.addChildDataNodes(DATASPACE_NAME, ANCHOR_NAME3, deleteTestParentXPath, [child]) and: 'number of children before delete is stored' def numberOfChildrenBeforeDelete = objectUnderTest.getDataNodes(DATASPACE_NAME, ANCHOR_NAME3, pathToParentOfDeletedNode, INCLUDE_ALL_DESCENDANTS)[0].childDataNodes.size() when: 'target node is deleted' -- cgit 1.2.3-korg