diff options
author | DylanB95EST <dylan.byrne@est.tech> | 2022-08-04 18:07:24 +0100 |
---|---|---|
committer | DylanB95EST <dylan.byrne@est.tech> | 2022-08-05 09:52:55 +0100 |
commit | e038e5b3c33348fa691765220476bfe3acba955c (patch) | |
tree | de35edbb9b39c011d9a6765f960447c69701aa79 /cps-ri/src/test/groovy | |
parent | 18cd7ed56f0afa07312694510f8e21fbcc32b993 (diff) |
Rename name column in yang resource table
- Rename name column in yang_resource table to file_name
- Refactor instances where it occures in code and tests
- Add new changelog file to rename occurance
Issue-ID: CPS-529
Change-Id: I2aff97410bdb041b90d8ceaeff75e562ef8d9238
Signed-off-by: DylanB95EST <dylan.byrne@est.tech>
Diffstat (limited to 'cps-ri/src/test/groovy')
-rw-r--r-- | cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceSpec.groovy | 6 | ||||
-rw-r--r-- | cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsModulePersistenceServiceIntegrationSpec.groovy | 3 |
2 files changed, 2 insertions, 7 deletions
diff --git a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceSpec.groovy b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceSpec.groovy index bb80199d09..bde2f3de9f 100644 --- a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceSpec.groovy +++ b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsDataPersistenceServiceSpec.groovy @@ -23,7 +23,6 @@ import com.fasterxml.jackson.databind.ObjectMapper import org.hibernate.StaleStateException import org.onap.cps.spi.FetchDescendantsOption import org.onap.cps.spi.entities.AnchorEntity -import org.onap.cps.spi.entities.DataspaceEntity import org.onap.cps.spi.entities.FragmentEntity import org.onap.cps.spi.entities.SchemaSetEntity import org.onap.cps.spi.entities.YangResourceEntity @@ -35,9 +34,6 @@ import org.onap.cps.spi.repository.DataspaceRepository import org.onap.cps.spi.repository.FragmentRepository import org.onap.cps.spi.utils.SessionManager import org.onap.cps.utils.JsonObjectMapper -import org.onap.cps.yang.YangTextSchemaSourceSet -import org.onap.cps.yang.YangTextSchemaSourceSetBuilder -import org.opendaylight.yangtools.yang.model.api.SchemaContext import spock.lang.Shared import spock.lang.Specification @@ -67,7 +63,7 @@ class CpsDataPersistenceServiceSpec extends Specification { @Shared def yangResourceSet = [new YangResourceEntity(moduleName: 'moduleName', content: NEW_RESOURCE_CONTENT, - name: 'sampleYangResource' + fileName: 'sampleYangResource' )] as Set diff --git a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsModulePersistenceServiceIntegrationSpec.groovy b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsModulePersistenceServiceIntegrationSpec.groovy index 8a43e5125d..3249d51ad1 100644 --- a/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsModulePersistenceServiceIntegrationSpec.groovy +++ b/cps-ri/src/test/groovy/org/onap/cps/spi/impl/CpsModulePersistenceServiceIntegrationSpec.groovy @@ -30,7 +30,6 @@ import org.onap.cps.spi.model.ModuleDefinition import org.onap.cps.spi.model.ModuleReference import org.onap.cps.spi.repository.AnchorRepository import org.onap.cps.spi.repository.SchemaSetRepository -import org.onap.cps.spi.repository.YangResourceRepository import org.springframework.beans.factory.annotation.Autowired import org.springframework.test.context.jdbc.Sql @@ -244,7 +243,7 @@ class CpsModulePersistenceServiceIntegrationSpec extends CpsPersistenceSpecBase // assert the attached yang resource content YangResourceEntity yangResourceEntity = yangResourceEntities.iterator().next() assert yangResourceEntity.id != null - yangResourceEntity.name == expectedYangResourceName + yangResourceEntity.fileName == expectedYangResourceName yangResourceEntity.content == expectedYangResourceContent yangResourceEntity.checksum == expectedYangResourceChecksum yangResourceEntity.moduleName == expectedYangResourceModuleName |