summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2020-05-18Refactor CsarUtil::extractVfcArtifactFrancis Toth2-38/+58
Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: Ica8d17d4f3c763920f406ccb89fb3e464d05eab4 Issue-ID: SDC-2812
2020-05-18Refactor tosca representation retrieval in CsarUtils::populateZipFrancis Toth1-30/+56
This commit aims to simplify CsarUtils::populateZip by extracting how a tosca representation is fetched to another function. this enables to reduce the overall cyclomatic complexity of the function. Some additional work still needs to be done especially regarding the ToscaRepresentation and MainYamlWithDependencies classes (These happen to be really similar). This will be done in another change in the near future. Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: I93600d0752565de523cf2285b1fa2ba43a96334f Issue-ID: SDC-2812
2020-05-18OrchestrationTemplateDaoZusammenImpl - Add tests for the presence of ↵Chris André1-28/+37
Optional values Issue-ID: SDC-3015 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: Iae0ce3d1b4bb5a72f04f0cd8a890c84eb15b214c
2020-05-17Remove powermock from ContextTrackerRodrigo Lima2-74/+78
- Remove powermock from ContextTrackerTest - Add package level constructor to ContextTracker to pass clear and put functions Issue-ID: SDC-3058 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I82519538b763b00f2768801f06929773bfb58013
2020-05-17Remove powermock from ValidationConfigManagerTestRodrigo Lima1-8/+2
- Remove powermock reference from ValidationConfigManagerTest Issue-ID: SDC-3064 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Ib330b0fcaf132e5d67f65b482a80b5b75f8c336b
2020-05-17Remove powermock from ArtifactValidationUtilsTestRodrigo Lima1-24/+17
- Remove powermock reference from ArtifactValidationUtilsTest - Use junit 5 imports instead of junit 4 Issue-ID: SDC-3067 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I6388e133024ed1e7604e90fc24ba3e84a33da4f7
2020-05-17Remove powermock from ReportManagerTestRodrigo Lima1-19/+9
- Remove powermock reference from ReportManagerTest - Use Junit 5 imports instead of junit 4 Issue-ID: SDC-3066 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Iece6e5741d5f2f5bc5db2ec7c85c63948776d601
2020-05-17Remove powermock from HostAddressCacheTestRodrigo Lima2-28/+51
- Remove powermock and easymock from HostAddressCacheTest - Add package level constructor to HostAddressCache and pass read address function to verified in unit test Issue-ID: SDC-3068 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I749211393d9e0ecb3ff3b587dc0f811b58bb967c
2020-05-17sdc-backend-init does not restart on healthcheck failureFuss, Areli (af732p)2-1/+3
Issue-ID: SDC-3063 Change-Id: I6c4a796f42060832ee8a37a708dedda7e7e98c70 Signed-off-by: Fuss, Areli (af732p) <areli.fuss@intl.att.com>
2020-05-17Fix edit deployment artifact icon, and downloadTufman, Shay (st198j)1-5/+10
Change-Id: I9e66870b03fcc5edcea30a18809cf8a2c539e674 Issue-ID: SDC-3053 Signed-off-by: Tufman, Shay (st198j) <st198j@att.com>
2020-05-17Work around potential NullPointerExceptions in ComponentInstanceOperationChris André1-36/+37
- Rewrite of `updateAttributeValueInResourceInstance` Issue-ID: SDC-2923 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I1becdec8c10515976835e7d8fb0208b9cbad10bb
2020-05-12Add tests for the presence of Optional valuesChris André1-11/+20
Issue-ID: SDC-3014 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I041c0109c41bb1a716792074c004fd8f54857038
2020-05-12Increase test coverage - openecomp-sdc-vendor-software-product-corevasraz14-0/+568
Change-Id: I1af31c1f14d72fbc30a026f7ae787ae9d4b03b36 Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-3001
2020-05-12Remove powermock from SecurityManagerTestRodrigo Lima2-15/+10
- Add new package level constructor to SecurityManager - Remove powermock from SecurityManagerTest Issue-ID: SDC-3054 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I04c53601f31d2aad84de8f8801f6889f8b9d4260
2020-05-12Remove unused ArtifactsBusinessLogic::updateArtifactsFlowForInterfaceOperationsFrancis Toth1-63/+0
This commit deletes the ArtifactsBusinessLogic::updateArtifactsFlowForInterfaceOperations function as it is no longer used anywhere. Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: I1dd950930485fc83bb02c889dafc5461192accbc Issue-ID: SDC-2812
2020-05-12Remove outputFullFilePath from ValidationConfigManagerFrancis Toth35-673/+629
This commit aims to extract the outputFullFilePath field from ValidationConfigManager in order to improve testability. This commit contains multiple minor modifications resulting from bubbling up the outputFullFilePath static field to where it is actually set. Most of the modifications result from changing the signature of the functions which formerly relied on ValidationConfigManager.getOutputFullFilePath. Change-Id: I0a28e527cabe606de8af62b8dcbc4b4e70db98ed Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Issue-ID: SDC-2499
2020-05-11Fix security issues in SecurityUtilNeil Derraugh2-203/+0
- Removed hard coded key - Specified mode and padding to address risky algorithm Issue-ID: SDC-3017 Signed-off-by: Neil Derraugh <neil.derraugh@yoppworks.com> Change-Id: I6c21174003fcb5669de49158d8dd6bf9907f50c6
2020-05-11Refactor CsarUtil::writeComponentInterfaceFrancis Toth1-18/+22
Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: I6a40119540c18469db44e218984b4d4b92d3f4af Issue-ID: SDC-2812
2020-05-11Refactor ArtifactsBusinessLogic::generateToscaArtifactFrancis Toth1-35/+55
This commit aims to refactor how Either is used in ArtifactsBusinessLogic::generateToscaArtifact. In order to keep the refactoring relatively small, we evalute its result at the call site. Change-Id: I669b30b44e9c69d1b3968fd719c5340b2dff83f5 Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Issue-ID: SDC-2812
2020-05-10Refactor to remove false positives from SonarChris André2-47/+111
- change `updateResourceInstancesNames` to account for case where `preparedResource` is null - change `findInputByName` to return an Either<InputDefinition, RuntimeException> in order to make exceptions explicit - create `rollbackWithEither` (+ tests) to make exceptions more explicit Issue-ID: SDC-2992 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I487994a3f9e88b0a2b14d2679c3587d85d8aa12d
2020-05-10Refactor ArtifactsBusinessLogic::handleDelete and ↵Francis Toth6-63/+53
ArtifactsBusinessLogic::deleteArtifactByInterface Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: I89f12c70f388375ed13554edf62bf6a442c9036a Issue-ID: SDC-2812
2020-05-10Allow any extension to WORKFLOW artifact typeandre.schmid1-2/+0
Allow any extension to WORKFLOW artifact as it was before the artifact type configuration change SDC-2754. Change-Id: I6c497cd83e36fe4df0cc800b9301010c22aa79f7 Issue-ID: SDC-3019 Signed-off-by: andre.schmid <andre.schmid@est.tech>
2020-05-10Remove powermock from ComponentProcessesImplTestRodrigo Lima2-44/+22
- Remove powermock from ComponentProcessesImplTest and add new constructor to ComponentProcessesImpl Issue-ID: SDC-3042 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I1766371a42a65d6b11c9b7b6783a312db2ed723e
2020-05-10Remove powermock from NicsImplTestRodrigo Lima2-35/+16
- Remove powermock from NicsImplTest and add new constructor to NicsImpl Issue-ID: SDC-3043 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Iec9343a403278f7db41d1654960c1060c3e75a99
2020-05-10Remove powermock from ImagesImplTestRodrigo Lima2-27/+17
- Remove powermock from ImagesImplTest and add new constructor to ImagesImpl Issue-ID: SDC-3038 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I6439a90a71d9de94c2233f8b64fed9da4860dd2e
2020-05-10Remove powermock from ComponentDependenciesImplTestRodrigo Lima2-27/+15
- Remove powermock from ComponentDependenciesImplTest and add new constructor to ComponentDependenciesImpl Issue-ID: SDC-3027 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I045e268230d94d4f52c4b85069eddade7678edee
2020-05-10Remove porwermock from ComponentImplTestRodrigo Lima2-27/+14
- Remove power mock from ComponentImplTest - Add new constructor to ComponentsImpl Issue-ID: SDC-3026 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I919fdb55990d813f4ac2950e3950b28e4686acbc
2020-05-10Remove powermock from ComponentMonitoringUploadsImplTestRodrigo Lima2-31/+19
- Remove powermock from ComponentMonitoringUploadsImplTest. - Add new constructor to ComponentMonitoringUploadsImpl. Issue-ID: SDC-3024 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Ic8583db9c459c4d39258129a3b70cc108b30d7de
2020-05-10Moved ArtifactsBusinessLogic::buildJsonStringForCsarVfcArtifact to JsonUtilsFrancis Toth4-28/+125
Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: Ia3bb9fe9f97e1759e4e5b70eb5e5396ed87d716d Issue-ID: SDC-2961
2020-05-10Remove powermock from ComputeImplTestRodrigo Lima2-35/+16
- Remove powermock from ComputeImplTest and add new constructor to ComputeImpl Issue-ID: SDC-3046 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Idf3e67c52f1d65e059bbcfcda5a477e2398b0a3e
2020-05-08Remove powermock from DeploymentFlavorsImplTestRodrigo Lima2-25/+14
- Remove powermock from DeploymentFlavorsImplTest and add new constructor to DeploymentFlavorsImpl Issue-ID: SDC-3050 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: Ib66937932c58c684de5e6a65fbcfb251c0b55c8e
2020-05-08Refactor CsarUtil::addComponentToCacheFrancis Toth1-17/+40
Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: Ib78be78780a97c873e710d805dd26273159d5354 Issue-ID: SDC-2812
2020-05-08Clean normatives file during mvn cleanandre.schmid1-3/+1
The configuration to clean the normatives.tar.gz was incorrect, so the file was not being cleaned up during mvn clean, which could create an inconsistent sdc-backend-init docker image. Change-Id: I15e3f4c49f404c147532c88c50f131cb61aea9c0 Issue-ID: SDC-3041 Signed-off-by: andre.schmid <andre.schmid@est.tech>
2020-05-07Reduce scope from 'compile' to 'test' for 'junit-vintage-engine'vasraz20-17/+27
Change-Id: I39b0be6ba6650c9a7215acf359f3d74e0a24e553 Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-2844 Issue-ID: SDC-2983
2020-05-07Support functions in TOSCA Simple Profile in YAMLvasraz29-84/+75
This commit aim to generalize usage of ToscaFunctions enum Change-Id: Iab3529e101f75db5f856778334a852afb532cdb6 Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-2982
2020-05-07Support configuring of tosca type for categoriesMichaelMorris8-353/+442
Signed-off-by: MichaelMorris <michael.morris@est.tech> Issue-ID: SDC-2877 Change-Id: I3160c5089979757628f31a44b01836236563b770
2020-05-06Prepare for Junit5vasraz94-8241/+8148
Remove unused/duplicated dependencies Change-Id: Iee0d9510ffbe3e2e14574e22ba965d6829fd568b Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-2844 Issue-ID: SDC-2983
2020-05-06Make `collectNewCapabilities` return an empty MapChris André1-4/+6
- Made `collectNewCapabilities` return an empty HashMap instead of a null value Issue-ID: SDC-2924 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I58c35135be5a2614c3daeafbd766d53f401f917b
2020-05-06Increase test coverage - openecomp-sdc-vendor-software-product-libvasraz75-2815/+695
Change-Id: Id51ce6f488efd6db02aad479ff419b58436be27c Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-3001
2020-05-06Increase test coverage - openecomp-sdc-tosca-generator-apivasraz12-774/+102
Change-Id: I1537d71b11ee440cb01bdee49350336f074ea36d Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-3001
2020-05-06Remove unused ES code and unneeded ES health checkNeil Derraugh1-12/+0
Remove the ES health check since ES was removed. Issue-ID: SDC-3022 Signed-off-by: neil.derraugh@yoppworks.com Change-Id: I918212de39d7b53959ac400975b3c47f889252c1
2020-05-06fix bug - Error 500 while adding an OperationYuli Shlosberg1-5/+0
Change-Id: I7def95b3688877acbc9332cf4174c9d92226f2e2 Issue-ID: SDC-2953 Signed-off-by: Yuli Shlosberg <ys9693@att.com>
2020-05-06fix bug - Unable to link CSAR artifactYuli Shlosberg2-5/+13
Change-Id: I586637f988b84b3b858e2c8d567c6844be38322b Issue-ID: SDC-2972 Signed-off-by: Yuli Shlosberg <ys9693@att.com>
2020-05-06Remove powermockito from OrchestrationTemplateCandidateImplTestRodrigo Lima2-45/+29
- Remove powermockito from OrchestrationTemplateCandidateImplTest. Add new constructor to OrchestrationTemplateCandidateImpl Issue-ID: SDC-3007 Signed-off-by: Rodrigo Lima <rodrigo.lima@yoppworks.com> Change-Id: I5f0a2061796e8410a5b225c43baa70d7e0269684
2020-05-06Handle null case in `addCalculatedCapabilitiesWithPropertiesToComponent`Chris André1-6/+15
- Change code to handle a null value for `groupDefinitions` as if it was an empty List Issue-ID: SDC-2910 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I5fca0ab76886e5f6a73a8f05ec35d38848f96dd8
2020-05-06Work around potential NullPointerExceptions in `ToscaOperationFacade`Chris André1-41/+64
- Add tests in `getToscaElementByOperation` and `updateToscaElement` for null values - rewrite `getLatestCertifiedByToscaResourceName` in a more functional way - Rewrite some other usages of Either in a more functional way Issue-ID: SDC-2922 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I52b294ec91faf9e1054af572dcca4060e62fe571
2020-05-05Setting default store types when not defined in configuration for init of ↵ilanap1-3/+4
https client Issue-ID: SDC-2962 Signed-off-by: ilanap <ilanap@amdocs.com> Change-Id: I9d88031c7d20951a4a77138340b1ddc26f47c0b6 Signed-off-by: ilanap <ilanap@amdocs.com>
2020-05-05Add tests for the presence of Optional valuesChris André1-14/+24
Issue-ID: SDC-3012 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I56cbf7fb5bd04ad2fbc496231d6abe72066124fe
2020-05-05UnifiedCompositionService - Refactor code to handle Optional valueChris André1-5/+2
Issue-ID: SDC-3015 Signed-off-by: Chris Andre <chris.andre@yoppworks.com> Change-Id: I1d15d20e9c603ff894c7c4be46b26d60745cb7e5
2020-05-05Replace hashCode and equals methods to cleanup NPE warningNeil Derraugh1-93/+13
Replace hashCode() and equals() with Lombok @EqualsAndHashCode(callSuper = true) Issue-ID: SDC-2925 Signed-off-by: neil.derraugh <neil.derraugh@yoppworks.com> Change-Id: I51056103dc7df953508b2e465a535b46c63e2667