diff options
author | danielhanrahan <daniel.hanrahan@est.tech> | 2023-04-05 16:16:56 +0100 |
---|---|---|
committer | danielhanrahan <daniel.hanrahan@est.tech> | 2023-04-11 13:20:45 +0100 |
commit | fe25cdbf4e97fb4d3bdbb32d5b0c02b75f80ba72 (patch) | |
tree | d2e3774ba99a94a2ea571cdb956984e88a71b386 /integration-test/src/test/groovy/org/onap | |
parent | da0192e77e40239a1f3ffb3d71dcf958e6e7cc8f (diff) |
Populate Dataspace field of DataNode
Issue-ID: CPS-1603
Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech>
Change-Id: I85aca8bccc28d36aa4cefa0a32cb9bdf2156618a
Diffstat (limited to 'integration-test/src/test/groovy/org/onap')
-rw-r--r-- | integration-test/src/test/groovy/org/onap/cps/integration/functional/CpsDataServiceIntegrationSpec.groovy | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/integration-test/src/test/groovy/org/onap/cps/integration/functional/CpsDataServiceIntegrationSpec.groovy b/integration-test/src/test/groovy/org/onap/cps/integration/functional/CpsDataServiceIntegrationSpec.groovy index c333911fcc..ddf8dcf874 100644 --- a/integration-test/src/test/groovy/org/onap/cps/integration/functional/CpsDataServiceIntegrationSpec.groovy +++ b/integration-test/src/test/groovy/org/onap/cps/integration/functional/CpsDataServiceIntegrationSpec.groovy @@ -21,12 +21,13 @@ package org.onap.cps.integration.functional +import org.onap.cps.api.CpsDataService import org.onap.cps.integration.base.FunctionalSpecBase import org.onap.cps.spi.FetchDescendantsOption class CpsDataServiceIntegrationSpec extends FunctionalSpecBase { - def objectUnderTest + CpsDataService objectUnderTest def setup() { objectUnderTest = cpsDataService } @@ -44,4 +45,14 @@ class CpsDataServiceIntegrationSpec extends FunctionalSpecBase { FetchDescendantsOption.INCLUDE_ALL_DESCENDANTS || 8 new FetchDescendantsOption(2) || 8 } + + def 'Read bookstore top-level container(s) has correct dataspace and anchor.'() { + when: 'get data nodes for bookstore container' + def result = objectUnderTest.getDataNodes(FUNCTIONAL_TEST_DATASPACE, BOOKSTORE_ANCHOR, '/bookstore', FetchDescendantsOption.INCLUDE_ALL_DESCENDANTS) + then: 'the correct dataspace was queried' + assert result.dataspace.toSet() == [FUNCTIONAL_TEST_DATASPACE].toSet() + and: 'the correct anchor was queried' + assert result.anchorName.toSet() == [BOOKSTORE_ANCHOR].toSet() + } + } |