diff options
author | Ittay Stern <ittay.stern@att.com> | 2018-12-31 17:21:27 +0200 |
---|---|---|
committer | Ittay Stern <ittay.stern@att.com> | 2019-01-09 20:19:55 +0200 |
commit | 6ad41e3ccd398a2721f41ad61c80b7bb03f7d127 (patch) | |
tree | 3bd672dff83e3218232cd8665680416b7fc26a5d /vid-automation/src/main | |
parent | 5ec29ff5e3864f1ba6ecac71f8bffbefa400cf27 (diff) |
Merge from ECOMP's repository
Main Features
--------------
- Async-Instantiation jobs mechanism major update; still WIP (package
`org.onap.vid.job`)
- New features in View/Edit: Activate fabric configuration; show
related networks; soft delete
- Support AAI service-tree traversal (`AAIServiceTree`)
- In-memory cache for SDC models and certain A&AI queries
(`CacheProviderWithLoadingCache`)
- Upgrade TOSCA Parser and add parsing options; fix malformed TOSCA
models
- Resolve Cloud-Owner values for MSO
- Pass X-ONAP headers to MSO
Infrastructure
--------------
- Remove codehaus' jackson mapper; use soley fasterxml 2.9.7
- Surefire invokes both TestNG and JUnit tests
- Support Kotlin source files
- AaiController2 which handles errors in a "Spring manner"
- Inline generated-sources and remove jsonschema2pojo
Quality
--------
- Cumulative bug fixes (A&AI API, UI timeouts, and many more)
- Many Sonar issues cleaned-up
- Some unused classes removed
- Minor changes in vid-automation project, allowing some API
verification to run
Hard Merges
------------
- HTTP Clients (MSO, A&AI, WebConfig, OutgoingRequestHeadersTest)
- Moved `package org.onap.vid.controllers` to `controller`, without
plural -- just to keep semantic sync with ECOMP.
Reference commit in ECOMP: 3d1141625
Issue-ID: VID-378
Change-Id: I9c8d1e74caa41815891d441fc0760bb5f29c5788
Signed-off-by: Ittay Stern <ittay.stern@att.com>
Diffstat (limited to 'vid-automation/src/main')
6 files changed, 5 insertions, 39 deletions
diff --git a/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOServiceInstanceGen2WithNames.java b/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOServiceInstanceGen2WithNames.java index 52c3071fa..98187b9a2 100644 --- a/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOServiceInstanceGen2WithNames.java +++ b/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOServiceInstanceGen2WithNames.java @@ -45,7 +45,7 @@ public abstract class PresetMSOServiceInstanceGen2WithNames extends PresetMSOBas " \"productFamilyId\": \"myProductFamilyId\"," + " \"source\": \"VID\"," + " \"suppressRollback\": false," + - " \"requestorId\": \"ab2222\"" + + " \"requestorId\": \"vid1\"" + " }," + " \"requestParameters\": {" + " \"subscriptionServiceType\": \"mySubType\"," + diff --git a/vid-automation/src/main/java/vid/automation/test/services/UsersService.java b/vid-automation/src/main/java/vid/automation/test/services/UsersService.java index 282be9067..ac8af4511 100644 --- a/vid-automation/src/main/java/vid/automation/test/services/UsersService.java +++ b/vid-automation/src/main/java/vid/automation/test/services/UsersService.java @@ -1,6 +1,5 @@ package vid.automation.test.services; -import com.att.automation.common.report_portal_integration.annotations.Step; import com.google.common.primitives.Ints; import org.apache.commons.lang3.StringUtils; import vid.automation.test.model.User; @@ -38,7 +37,6 @@ public class UsersService { return usersObject.users; } - @Step("${method} with id: ${userId}") public User getUser(String userId) { User res = users.get(userId); System.out.println("getUser userId='" + userId + "' returned: " + res); diff --git a/vid-automation/src/main/java/vid/automation/test/test/VidBaseTestCase.java b/vid-automation/src/main/java/vid/automation/test/test/VidBaseTestCase.java index 5c0206c06..e5a8b5786 100644 --- a/vid-automation/src/main/java/vid/automation/test/test/VidBaseTestCase.java +++ b/vid-automation/src/main/java/vid/automation/test/test/VidBaseTestCase.java @@ -1,23 +1,11 @@ package vid.automation.test.test; -import com.att.automation.common.report_portal_integration.annotations.Step; -import com.att.automation.common.report_portal_integration.listeners.ReportPortalListener; -import com.att.automation.common.report_portal_integration.screenshots.WebDriverScreenshotsProvider; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.collect.ImmutableList; import org.apache.commons.lang3.StringUtils; import org.junit.Assert; import org.onap.simulator.presetGenerator.presets.BasePresets.BasePreset; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAICloudRegionAndSourceFromConfigurationPut; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetNetworkZones; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetPortMirroringSourcePorts; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetServicesGet; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetSubDetailsGet; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetSubscribersGet; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIGetTenants; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIPostNamedQueryForViewEdit; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAISearchNodeQueryEmptyResult; -import org.onap.simulator.presetGenerator.presets.aai.PresetAAIServiceDesignAndCreationPut; +import org.onap.simulator.presetGenerator.presets.aai.*; import org.onap.simulator.presetGenerator.presets.ecompportal_att.PresetGetSessionSlotCheckIntervalGet; import org.onap.simulator.presetGenerator.presets.mso.PresetMSOCreateServiceInstanceGen2; import org.onap.simulator.presetGenerator.presets.mso.PresetMSOCreateServiceInstancePost; @@ -34,7 +22,6 @@ import org.openqa.selenium.WebElement; import org.testng.ITestContext; import org.testng.annotations.BeforeMethod; import org.testng.annotations.BeforeSuite; -import org.testng.annotations.Listeners; import org.testng.annotations.Test; import vid.automation.test.Constants; import vid.automation.test.infra.*; @@ -60,7 +47,6 @@ import static org.hamcrest.core.Is.is; import static org.testng.Assert.assertEquals; import static org.testng.AssertJUnit.fail; -@Listeners(com.att.automation.common.report_portal_integration.listeners.ReportPortalListener.class) public class VidBaseTestCase extends SetupCDTest{ protected final UsersService usersService = new UsersService(); @@ -109,7 +95,7 @@ public class VidBaseTestCase extends SetupCDTest{ @BeforeSuite(alwaysRun = true) public void screenShotsForReportPortal(){ try { - ReportPortalListener.setScreenShotsProvider(new WebDriverScreenshotsProvider(getDriver())); + //ReportPortalListener.setScreenShotsProvider(new WebDriverScreenshotsProvider(getDriver())); System.out.println("Called to ReportPortalListener to set ScreenShotsProvider"); } catch (Exception e) { e.printStackTrace(); @@ -301,7 +287,6 @@ public class VidBaseTestCase extends SetupCDTest{ Assert.assertTrue(Constants.ViewEdit.VF_MODULE_CREATION_FAILED_MESSAGE, byText); } - @Step("${method}: ${instanceUUID}") void goToExistingInstanceById(String instanceUUID) { SearchExistingPage searchExistingPage = searchExistingInstanceById(instanceUUID); assertViewEditButtonState( Constants.VIEW_EDIT_BUTTON_TEXT, instanceUUID); diff --git a/vid-automation/src/main/java/vid/automation/test/test/ViewEditServiceInstanceTest.java b/vid-automation/src/main/java/vid/automation/test/test/ViewEditServiceInstanceTest.java index e07acc3ac..3b9546fdd 100644 --- a/vid-automation/src/main/java/vid/automation/test/test/ViewEditServiceInstanceTest.java +++ b/vid-automation/src/main/java/vid/automation/test/test/ViewEditServiceInstanceTest.java @@ -28,7 +28,6 @@ import java.util.Map; import java.util.regex.Matcher; import java.util.regex.Pattern; -import static org.apache.logging.log4j.core.util.Assert.isNonEmpty; import static org.hamcrest.Matchers.equalTo; import static org.testng.AssertJUnit.assertEquals; import static vid.automation.test.infra.Features.FLAG_COLLECTION_RESOURCE_SUPPORT; @@ -359,7 +358,7 @@ public class ViewEditServiceInstanceTest extends VidBaseTestCase { "pending-delete", false); for(Map.Entry<String, Boolean> entry: vfModulesStatuses.entrySet()) { WebElement vfModule = GeneralUIUtils.getWebElementByClassName("vfModuleTreeNode-" + entry.getKey()); - Assert.assertEquals(isNonEmpty(vfModule.findElements(By.className("resume"))), entry.getValue()); + Assert.assertEquals(!vfModule.findElements(By.className("resume")).isEmpty(), entry.getValue()); } } diff --git a/vid-automation/src/main/java/vid/automation/test/utils/DB_CONFIG.java b/vid-automation/src/main/java/vid/automation/test/utils/DB_CONFIG.java index 18cda6bda..ef5625232 100644 --- a/vid-automation/src/main/java/vid/automation/test/utils/DB_CONFIG.java +++ b/vid-automation/src/main/java/vid/automation/test/utils/DB_CONFIG.java @@ -1,7 +1,7 @@ package vid.automation.test.utils; public class DB_CONFIG { - public static String url = String.format("jdbc:mariadb://%s:%d/vid_portal", + public static String url = String.format("jdbc:mariadb://%s:%d/vid_openecomp_epsdk", System.getProperty("DB_HOST", System.getProperty("VID_HOST", "127.0.0.1" )), Integer.valueOf(System.getProperty("DB_PORT", "3306")) ); diff --git a/vid-automation/src/main/resources/META-INF/aop-ajc.xml b/vid-automation/src/main/resources/META-INF/aop-ajc.xml index 7376e3291..77505c753 100644 --- a/vid-automation/src/main/resources/META-INF/aop-ajc.xml +++ b/vid-automation/src/main/resources/META-INF/aop-ajc.xml @@ -1,18 +1,2 @@ <aspectj> - <aspects> - <aspect name="com.att.automation.common.report_portal_integration.aspects.StepAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.WebDriverAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.AssertAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.WireMockAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.RestAssuredAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.ReportPortalAspects"/> - <aspect name="com.att.automation.common.report_portal_integration.aspects.LatticeAspects"/> - </aspects> - <weaver options="-Xset:weaveJavaxPackages=true -warn:none -Xlint:ignore"> - <include within="vid.automation..*"/> - <include within="org.onap..*"/> - <include within="com.att.automation..*"/> - <include within="com.epam..*"/> - <include within="org.testng.TestNG"/> - </weaver> </aspectj>
\ No newline at end of file |