Fixes for portal App Access tests 43/99443/4
authorBrian Freeman <bf1936@att.com>
Tue, 10 Dec 2019 20:36:01 +0000 (15:36 -0500)
committerBrian Freeman <bf1936@att.com>
Wed, 11 Dec 2019 19:36:31 +0000 (14:36 -0500)
Issue-ID: PORTAL-782
Change-Id: I573f18e653bc008c4454775d80120fc891290fde
Signed-off-by: Brian Freeman <bf1936@att.com>
robot/resources/portal-sdk/portalDef.robot
robot/resources/portal_interface.robot
robot/testsuites/health-check.robot
robot/testsuites/portalApp.robot

index 6ecfd82..a2ea59e 100644 (file)
@@ -40,8 +40,9 @@ Generate Random User
 
 Portal admin Login To Portal GUI
     [Documentation]   Logs into Portal GUI
-    Set Selenium Speed    ${GLOBAL_SELENIUM_DELAY}
     Setup Browser
+    Set Selenium Speed    ${GLOBAL_SELENIUM_DELAY}
+    Set Window Size        2000   1000
     Go To    ${PORTAL_LOGIN_URL}
     Set Browser Implicit Wait    ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT}
     Log    Logging in to ${PORTAL_URL}${PORTAL_ENV}
index 402a750..18ff966 100644 (file)
@@ -12,7 +12,9 @@ Resource        browser_setup.robot
 *** Variables ***
 ${PORTAL_HEALTH_CHECK_PATH}        /ONAPPORTAL/portalApi/healthCheck
 ${PORTAL_ENDPOINT}     ${GLOBAL_PORTAL_SERVER_PROTOCOL}://${GLOBAL_INJECTED_PORTAL_IP_ADDR}:${GLOBAL_PORTAL_SERVER_PORT}
-${PORTAL_GUI_ENDPOINT}     ${GLOBAL_PORTAL_SERVER_PROTOCOL}://portal.api.simpledemo.onap.org:${GLOBAL_PORTAL_SERVER_PORT}
+#${PORTAL_GUI_ENDPOINT}     ${GLOBAL_PORTAL_SERVER_PROTOCOL}://portal.api.simpledemo.onap.org:${GLOBAL_PORTAL_SERVER_PORT}
+#${PORTAL_GUI_ENDPOINT}     ${GLOBAL_PORTAL_SERVER_PROTOCOL}://portal-app.onap:${GLOBAL_PORTAL_SERVER_PORT}
+${PORTAL_GUI_ENDPOINT}     https://portal.api.simpledemo.onap.org:30225
 ${PORTAL_ENV}            /ONAPPORTAL
 ${PORTAL_LOGIN_URL}                ${PORTAL_GUI_ENDPOINT}${PORTAL_ENV}/login.htm
 ${PORTAL_HOME_URL}                ${PORTAL_GUI_ENDPOINT}${PORTAL_ENV}/applicationsHome
@@ -50,12 +52,21 @@ Run Portal Login Tests
 
 Run Portal Application Access Tests
      [Documentation]    Runs Portal Application Access Tests
-     Log    Testing SDC,VID,Policy
-     Run Portal Application Login Test   cs0008   demo123456!   gridster-SDC-icon-link   tabframe-SDC    Welcome to SDC
+     Log    Testing SDC,VID,Policy    console=yes
+     ${status}   ${resp}    Run Keyword And Ignore Error   Run Portal Application Login Test   cs0008   demo123456!   gridster-SDC-icon-link   tabframe-SDC    Welcome to SDC
+     Log    SDC ${status}   console=yes
      Close All Browsers
-     Run Portal Application Login Test   demo    demo123456!  gridster-Virtual-Infrastructure-Deployment-icon-link   tabframe-Virtual-Infrastructure-Deployment    Welcome to VID
+     ${status}   ${resp}    Run Keyword And Ignore Error   Run Portal Application Login Test   demo    demo123456!  gridster-Virtual-Infrastructure-Deployment-icon-link   tabframe-Virtual-Infrastructure-Deployment    Welcome to VID
+     Log    VID ${status}   console=yes
      Close All Browsers
-     Run Portal Application Login Test   demo    demo123456!  gridster-Policy-icon-link   tabframe-Policy    Policy Editor
+     ${status}   ${resp}    Run Keyword And Ignore Error   Run Portal Application Login Test   demo    demo123456!  gridster-A&AI-UI-icon-link   tabframe-A&AI-UI    A&AI
+     Log    A&AI UI ${status}   console=yes
+     Close All Browsers
+     ${status}   ${resp}    Run Keyword And Ignore Error   Run Portal Application Login Test   demo    demo123456!  gridster-Policy-icon-link   tabframe-Policy    Policy Editor
+     Log    Policy ${status}    console=yes
+     Close All Browsers
+     ${status}   ${resp}    Run Keyword And Ignore Error   Run Portal Application Login Test   demo    demo123456!  gridster-SO-Monitoring-icon-link   tabframe-SO-Monitoring   SO 
+     Log    SO-Monitoring ${status}   console=yes
      Close All Browsers
 
 Login To Portal GUI And Go Home
@@ -76,10 +87,14 @@ Login To Portal GUI
     Log    Logging in to ${PORTAL_ENDPOINT}${PORTAL_ENV}
     Handle Proxy Warning
     Title Should Be    Login
+    Log Source
     Input Text    xpath=//input[@ng-model='loginId']    ${loginId}
     Input Password    xpath=//input[@ng-model='password']    ${password}
     Click Element    xpath=//a[@id='loginBtn']
-    Wait Until Page Contains  Applications   ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}
+    Sleep   5s
+    #Go To     ${PORTAL_HOME_URL}                
+    #Wait Until Page Contains  Applications   ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}
+    Wait Until Page Contains  Applications   30
     Log    Logged in to ${PORTAL_ENDPOINT}${PORTAL_ENV}
     Log  ${loginId} SUCCESS
     
@@ -96,6 +111,7 @@ Run Portal Application Login Test
     # Setup Browser Now being managed by test case
     ### revert to local Setup Browser for Login test
     Setup Browser
+    Set Window Size        2000   1000
     Go To    ${PORTAL_LOGIN_URL}
     #Maximize Browser Window
     Set Selenium Speed    ${GLOBAL_SELENIUM_DELAY}
@@ -106,6 +122,8 @@ Run Portal Application Login Test
     Input Text    xpath=//input[@ng-model='loginId']    ${loginId}
     Input Password    xpath=//input[@ng-model='password']    ${password}
     Click Element    xpath=//a[@id='loginBtn']
+    Sleep   5s
+    #Go To     ${PORTAL_HOME_URL}                
     Wait Until Page Contains  Applications   ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}
     Log    Logged in to ${PORTAL_ENDPOINT}${PORTAL_ENV}
     Log  ${loginId} SUCCESS
@@ -114,8 +132,7 @@ Run Portal Application Login Test
     Sleep  5
     Select Frame  id=${tabframe}
     Sleep  5
-    Page Should Contain  ${match_string}
-    Log   Portal Application Access SUCCESS ${click_element}
+    Wait Until Page Contains   ${match_string}     60
 
 Go To Portal HOME
     [Documentation]    Naviage to Portal Home
index b37ec4e..c8ec297 100644 (file)
@@ -280,13 +280,57 @@ Health Distribution Test
 
 Portal Login Tests
     [Tags]    healthlogin
+    [Timeout]   120
     Run Portal Login Tests
 
 Portal Application Access Tests
     [Tags]    healthportalapp
-    [Timeout]    180
+    [Timeout]    900
     Run Portal Application Access Tests
 
+Portal SDC Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   cs0008   demo123456!   gridster-SDC-icon-link   tabframe-SDC    Welcome to SDC
+    Close All Browsers
+
+Portal VID Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-Virtual-Infrastructure-Deployment-icon-link   tabframe-Virtual-Infrastructure-Deployment    Welcome to VID
+    Close All Browsers
+
+Portal A&AI UI Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-A&AI-UI-icon-link   tabframe-A&AI-UI    A&AI
+    Close All Browsers
+
+Portal Policy Editor Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-Policy-icon-link   tabframe-Policy    Policy Editor
+    Close All Browsers
+
+Portal SO Monitoring Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-SO-Monitoring-icon-link   tabframe-SO-Monitoring   SO
+    Close All Browsers
+
+Portal xDemo APP Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-xDemo-App-icon-link   tabframe-xDemo-App   xDemo
+    Close All Browsers
+
+Portal CLI Application Access Test
+    [Tags]    healthportalapp2
+    [Timeout]    180
+    Run Portal Application Login Test   demo    demo123456!  gridster-CLI-icon-link   tabframe-CLI   CLI
+    Close All Browsers
+
+
 Basic Holmes Rule Management API Health Check
     [Tags]    health    medium   health-dcaegen2
     Run Holmes Rule Mgmt Healthcheck
index 0301ca4..f62719e 100644 (file)
@@ -9,29 +9,29 @@ Suite Teardown  Close All Browsers
 *** Test Cases ***
 
 Login into Portal URL
-    [TAGS]  portal
+    [TAGS]  portal    portal-ci
     Portal admin Login To Portal GUI
 
 Portal Change REST URL Of X-DemoApp
-    [TAGS]  portal
+    [TAGS]  portal    portal-ci
     [Documentation]    Portal Change REST URL Of X-DemoApp
     Portal Change REST URL
 
 Portal R1 Release for AAF
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     [Documentation]    ONAP Portal R1 functionality for AAF test
     Portal AAF new fields
 
 EP Admin widget layout reset
-    [TAGS]  portalSKIP
+    [TAGS]  portalSKIP   portal-ci 
     Reset widget layout option
 
 Validate Functional Top Menu Get Access
-    [TAGS]  portal
+    [TAGS]  portal    portal-ci
     Functional Top Menu Get Access
 
 Validate Functional Top Menu Contact Us
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     Functional Top Menu Contact Us
 
 Edit Functional Menu
@@ -39,17 +39,17 @@ Edit Functional Menu
     Portal admin Edit Functional menu
 
 Create a Test user for Application Admin -Test
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     ${login_id}    ${email_address}=    Generate Random User    portal
     Portal admin Add Application admin User New user -Test    ${login_id}    ${email_address}
 
 Create a Test User for Application Admin
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     ${login_id}    ${email_address}=    Generate Random User    demoapp
     Portal admin Add Application admin User New user    ${login_id}    ${email_address}
 
 Add Application Admin for Existing User Test user
-    [TAGS]  portal
+    [TAGS]  portal   
     ${login_id}    ${email_address}=    Generate Random User    demoapp
     Portal admin Add Application Admin Existing User -APPDEMO    ${login_id}
 
@@ -69,23 +69,23 @@ Delete Application Admin for Existing User
     Portal admin Delete Application Admin Existing User    ${login_id}
 
 Logout from Portal GUI as Portal Admin
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     Portal admin Logout from Portal GUI
 
 # Application Admin user Test cases
 
 Login To Portal GUI as APP Admin
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     ${login_id}    ${email_address}=    Generate Random User    demoapp
     Application admin Login To Portal GUI    ${login_id}
 
 Logout from Portal GUI as APP Admin
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     Application admin Logout from Portal GUI
 
 #Standard User Test cases
 
 Logout from Portal GUI as Standard User
-    [TAGS]  portal
+    [TAGS]  portal   portal-ci
     Standard User Logout from Portal GUI
     Close All Browsers