Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[18.0.-fr1] Add required test variables into horizon.conf #237

Open
wants to merge 1 commit into
base: 18.0-fr1
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions container-images/tcib/base/os/horizontest/run_horizontest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@ SELENIUM_EXPLICIT_WAIT=180
SELENIUM_PAGE_TIMEOUT=120
SELENIUM_IMPLICIT_WAIT=30
HORIZONTEST_DEBUG_MODE="${HORIZONTEST_DEBUG_MODE:-false}"
SUBNET_NAME=public_subnet
PROJECT_NAME_XPATH="//span[@class='rcueicon rcueicon-folder-open']/ancestor::li"
HELP_SEQUENCE=".//*[normalize-space()='Help']"
HELP_URL="https://docs.redhat.com/en/documentation/red_hat_openstack_services_on_openshift/"
TEST_MATERIAL_THEME=False
USER_NAME_XPATH="//span[@class='rcueicon rcueicon-user']/ancestor::li"
BROWSE_LEFT_PANEL_MAIN="Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Project,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Admin,Identity,Identity,Identity,Identity,Identity"
BROWSE_LEFT_PANEL_SEC="Project,None,None,None,None,None,Volumes,Volumes,Network,Network,Network,Network,Network,Network,Network,Object Store,None,Compute,Compute,Compute,Compute,Compute,Volume,Volume,Volume,Volume,Network,Network,Network,Network,Network,System,System,System,None,None,None,None,None"
BLP_SEC_LINE_XPATH=".//*[@class='navbar primary persistent-secondary']"
BLP_SEC_LINE_REQ_BTN=".//*[@class='navbar primary persistent-secondary']//a[normalize-space()='{sec_panel}']//ancestor::li"
BLP_SIDEBAR_XPATH=".//*[@class='navbar primary persistent-secondary']//a[normalize-space()='{sec_panel}']//ancestor::li//*[@class='dropdown-menu']"

# assert mandatory variables have been set
[[ -z ${ADMIN_USERNAME} ]] && echo "ADMIN_USERNAME not set" && exit 1
Expand Down Expand Up @@ -125,6 +136,7 @@ pushd ${HORIZONTEST_DIR}/horizon/openstack_dashboard/test/integration_tests/
# set variables in horizon.conf
crudini --set horizon.conf dashboard dashboard_url ${DASHBOARD_URL}/dashboard/
crudini --set horizon.conf dashboard auth_url ${AUTH_URL}
crudini --set horizon.conf dashboard help_url ${HELP_URL}
crudini --set horizon.conf identity username ${USER_NAME}
crudini --set horizon.conf identity password ${PASSWORD}
crudini --set horizon.conf identity home_project ${PROJECT_NAME}
Expand All @@ -136,6 +148,16 @@ crudini --set horizon.conf launch_instances image_name "${IMAGE_FILE_NAME_WITH_S
crudini --set horizon.conf selenium explicit_wait ${SELENIUM_EXPLICIT_WAIT}
crudini --set horizon.conf selenium page_timeout ${SELENIUM_PAGE_TIMEOUT}
crudini --set horizon.conf selenium implicit_wait ${SELENIUM_IMPLICIT_WAIT}
crudini --set horizon.conf network subnet_name ${SUBNET_NAME}
crudini --set horizon.conf theme project_name_xpath "${PROJECT_NAME_XPATH}"
crudini --set horizon.conf theme help_sequence "${HELP_SEQUENCE}"
crudini --set horizon.conf theme test_material_theme "${TEST_MATERIAL_THEME}"
crudini --set horizon.conf theme user_name_xpath "${USER_NAME_XPATH}"
crudini --set horizon.conf theme browse_left_panel_main "${BROWSE_LEFT_PANEL_MAIN}"
crudini --set horizon.conf theme browse_left_panel_sec "${BROWSE_LEFT_PANEL_SEC}"
crudini --set horizon.conf theme b_l_p_sec_line_xpath "${BLP_SEC_LINE_XPATH}"
crudini --set horizon.conf theme b_l_p_sec_line_req_btn "${BLP_SEC_LINE_REQ_BTN}"
crudini --set horizon.conf theme b_l_p_sidebar_xpath "${BLP_SIDEBAR_XPATH}"
popd

# run horizon selenium tests
Expand Down
Loading