From 5f9f3ccf917d91e2af7f29a467a451d6274912a7 Mon Sep 17 00:00:00 2001 From: demskeq8 Date: Mon, 4 Sep 2023 17:59:57 +0200 Subject: [CSIT] update SDNR tests for mariaDB based sdnrdb update SDNC test image deploy sdnc-web-image for sdnr test setup add healthcheck add basic odlux tests Issue-ID: SDNC-1820 Change-Id: Ib89d097f301bfe4803bf3006549bee9a78fb6c19 Signed-off-by: demskeq8 --- .../tests/sdnr/healthcheck/20_healthcheckSUT.robot | 10 ++-- .../odlux/50_side_bar_elements_ODLUX_check.robot | 53 ++++++++++++++++++++++ .../onfcore14-basic-odlux/10_lifecycleNetconfSsh | 1 + .../22_alarmNotificationNETCONF | 1 + .../onfcore14-basic-odlux/90_resetSimulatedDevices | 1 + .../odlux/onfcore14-basic-odlux/__init__.robot | 20 ++++++++ .../onfcore14-basic-odlux/yangCapabilities.txt | 51 +++++++++++++++++++++ 7 files changed, 134 insertions(+), 3 deletions(-) create mode 100644 csit/tests/sdnr/odlux/50_side_bar_elements_ODLUX_check.robot create mode 120000 csit/tests/sdnr/odlux/onfcore14-basic-odlux/10_lifecycleNetconfSsh create mode 120000 csit/tests/sdnr/odlux/onfcore14-basic-odlux/22_alarmNotificationNETCONF create mode 120000 csit/tests/sdnr/odlux/onfcore14-basic-odlux/90_resetSimulatedDevices create mode 100644 csit/tests/sdnr/odlux/onfcore14-basic-odlux/__init__.robot create mode 100644 csit/tests/sdnr/odlux/onfcore14-basic-odlux/yangCapabilities.txt (limited to 'csit/tests/sdnr') diff --git a/csit/tests/sdnr/healthcheck/20_healthcheckSUT.robot b/csit/tests/sdnr/healthcheck/20_healthcheckSUT.robot index 2d29c9f0..7eee7ad7 100644 --- a/csit/tests/sdnr/healthcheck/20_healthcheckSUT.robot +++ b/csit/tests/sdnr/healthcheck/20_healthcheckSUT.robot @@ -3,7 +3,7 @@ Documentation healthcheck of system under test: sdnc server, sdnrdb are availab Library ConnectLibrary Library SDNCBaseLibrary Library Collections -Library ElasticSearchLibrary +Library SDNRDBLib Library ConnectApp Library RequestsLibrary @@ -12,7 +12,6 @@ Suite Teardown global suite teardown *** Variables *** &{headers} Content-Type=application/json Authorization=Basic - *** Test Cases *** Test Is SDNR Node Available ${server_status}= Server Is Ready @@ -25,7 +24,7 @@ Test Is SDNRDB Available Test Is SDNRDB Initialized ${res}= Check Aliases - Log ${res} level=INFO html=False console=False repr=False + Log ${res} level=INFO Test Is VES Collector available # curl -k -u sample1:sample1 https://172.40.0.1:8443 @@ -42,3 +41,8 @@ Test Is VES Collector available Should Be Equal As Strings ${resp.status_code} 200 RequestsLibrary.Delete All Sessions +Test Version Info Contains Correct release + ${VERSION_INFO_DICT}= get_version_info_as_dict + ${release}= Get From Dictionary ${VERSION_INFO_DICT["""version-info"""]} Opendaylight-release + Should Contain ${release} ${RELEASE_VERSION} + diff --git a/csit/tests/sdnr/odlux/50_side_bar_elements_ODLUX_check.robot b/csit/tests/sdnr/odlux/50_side_bar_elements_ODLUX_check.robot new file mode 100644 index 00000000..7b3116bd --- /dev/null +++ b/csit/tests/sdnr/odlux/50_side_bar_elements_ODLUX_check.robot @@ -0,0 +1,53 @@ +*** Settings *** +Documentation Test to verify the existence and functionality of the ODLUX Side-Bar Elements. + ... Opens ODLUX and clicks on each Side-Bar Element (Data-driven), given in the SIDE_BAR_ELEMENT + ... column. Once clicking on the Side-Bar Element has been successful, a clickable web-element + ... given by the locator in the CHECK_CLICKABLE_BUTTON_VALUE column, will be checked for existence. + ... The web-element's By strategy to find the element, given by the CHECK_CLICKABLE_BUTTON_BY column, + ... (either Xpath or CSS_SELECTOR) has to be provided and is depended on the variable locator. + ... The test will Pass if both the Side-Bar Element and the clickable web-element exist, else Fail. +Library UILib +Library Collections + +Test Template Check Side Bar Elements + +*** Variables *** +${MAKE_SCREENSHOTS} ${True} +${ELEMENT_COUNT} ${0} + +*** Test Cases *** SIDE_BAR_ELEMENT CHECK_WEBELEMENT_BY CHECK_WEBELEMENT_VALUE CLICK_ON_WEB_ELEMET +Check if Side Bar Element Home exists Home CSS_SELECTOR ODLUX_WELCOME_TO_ODLUX_LABEL False +Check if Side Bar Element Connect exists Connect CSS_SELECTOR ODLUX_NETWORK_ELEMENTS_LIST_TAB_LABEL False +Check if Side Bar Element Fault exists Fault CSS_SELECTOR ODLUX_CURRENT_ALARMS_TABLE_LABEL False +Check if Side Bar Element Maintenance exists Maintenance CSS_SELECTOR ODLUX_MAINTENANCE_TABLE_FILTER_LIST_BUTTON_LABEL False +Check if Side Bar Element Configuration exists Configuration CSS_SELECTOR ODLUX_TABLE_FILTER_LIST_BUTTON_LABEL False +Check if Side Bar Element Performance exists Performance CSS_SELECTOR ODLUX_PERFORMANCE_TABLE_FILTER_LIST_BUTTON_LABEL False +Check if Side Bar Element Inventory exists Inventory CSS_SELECTOR ODLUX_INVENTORY_TABLE_LABEL False +Check if Side Bar Element Event_Log exists Event_Log CSS_SELECTOR ODLUX_EVENT_LOG_TABLE_FILTER_LIST_BUTTON_LABEL False +Check if Side Bar Element Help exists Help CSS_SELECTOR ODLUX_HELP_AND_FAQ_LABEL False +Check if Side Bar Element About exists About CSS_SELECTOR ODLUX_ABOUT_COPY_TO_CLIPBOARD_LABEL False + +Sidebar Elements Count + [Template] Check Side Bar Elements Count + ${ELEMENT_COUNT} + +*** Keywords *** +Check Side Bar Elements + [Arguments] ${side_bar_element} ${check_webelement_by} ${check_webelement_value} ${click_on_web_element} + ${ELEMENT_COUNT}= Set Variable ${${ELEMENT_COUNT}+${1}} + Set Suite Variable ${ELEMENT_COUNT} + Refresh Current Browser Tab + Log ${side_bar_element} + UILib.Click On Site Bar Element side_bar_element=${side_bar_element} + ${is_exist}= Check If Web Element Exists by=${check_webelement_by} value=${check_webelement_value} + ... click_on_web_element=${click_on_web_element} + Should Be True ${is_exist} + +Check Sidebar Elements Count + [Arguments] ${elements_count} + ${sidebar_elements}= Get All Sidebar Elements + Log ${sidebar_elements} + ${current_sidebar_elements_count}= Get Length ${sidebar_elements} + Should Be Equal As Integers ${elements_count} ${current_sidebar_elements_count} + + diff --git a/csit/tests/sdnr/odlux/onfcore14-basic-odlux/10_lifecycleNetconfSsh b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/10_lifecycleNetconfSsh new file mode 120000 index 00000000..fe272974 --- /dev/null +++ b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/10_lifecycleNetconfSsh @@ -0,0 +1 @@ +../../functional/devicemanager/_templates/10_lifecycleNetconfSsh \ No newline at end of file diff --git a/csit/tests/sdnr/odlux/onfcore14-basic-odlux/22_alarmNotificationNETCONF b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/22_alarmNotificationNETCONF new file mode 120000 index 00000000..4a3946f9 --- /dev/null +++ b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/22_alarmNotificationNETCONF @@ -0,0 +1 @@ +../../functional/devicemanager/_templates/22_alarmNotificationNETCONF \ No newline at end of file diff --git a/csit/tests/sdnr/odlux/onfcore14-basic-odlux/90_resetSimulatedDevices b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/90_resetSimulatedDevices new file mode 120000 index 00000000..423c96aa --- /dev/null +++ b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/90_resetSimulatedDevices @@ -0,0 +1 @@ +../../functional/devicemanager/_templates/90_resetSimulatedDevices/ \ No newline at end of file diff --git a/csit/tests/sdnr/odlux/onfcore14-basic-odlux/__init__.robot b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/__init__.robot new file mode 100644 index 00000000..15e6f2ef --- /dev/null +++ b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/__init__.robot @@ -0,0 +1,20 @@ +*** Settings *** +Documentation Test suite for onf core 1.4 devices via odlux +Suite Setup My Setup +Force Tags onf-core-14 +Library OperatingSystem + +*** Variables *** + + +*** Keywords *** +My Setup + Set Suite Variable ${USE_SELENIUM} ${True} + Set Suite Variable ${DEVICE_TYPE} ONF_CORE_1_4 children=true + Set Suite Variable ${CORE_MODEL} 2019-11-27 children=true + Set Suite Variable ${DEVICE_TYPE_GUI} Wireless children=true + ${yang_file} = Get File ${CURDIR}/yangCapabilities.txt + Set Suite Variable ${YANG_CAPABILITIES_FILE} ${yang_file} children=true + Set Suite Variable ${IS_SUPERVISION_ALARM} ${True} + + diff --git a/csit/tests/sdnr/odlux/onfcore14-basic-odlux/yangCapabilities.txt b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/yangCapabilities.txt new file mode 100644 index 00000000..ddc11cca --- /dev/null +++ b/csit/tests/sdnr/odlux/onfcore14-basic-odlux/yangCapabilities.txt @@ -0,0 +1,51 @@ +[["ethernet-container-2-0", "2020-01-21"], + ["ietf-crypto-types", "2019-07-02"], + ["ietf-netconf-notifications", "2012-02-06"], + ["ietf-yang-types", "2013-07-15"], + ["vlan-fd-1-0", "2021-01-05"], + ["ietf-tcp-server", "2019-07-02"], + ["yang", "2017-02-20"], + ["notifications", "2008-07-14"], + ["iana-crypt-hash", "2014-08-06"], + ["ietf-origin", "2018-02-14"], + ["wred-profile-1-0", "2020-01-24"], + ["ietf-netconf-monitoring", "2010-10-04"], + ["ietf-tls-common", "2019-07-02"], + ["ietf-netconf-server", "2019-07-02"], + ["mac-fd-1-0", "2020-08-26"], + ["wire-interface-2-0", "2020-01-23"], + ["ietf-ssh-common", "2019-07-02"], + ["qos-profile-1-0", "2020-01-24"], + ["mac-interface-1-0", "2020-01-23"], + ["ietf-ssh-server", "2019-07-02"], + ["ietf-netconf-with-defaults", "2011-06-01"], + ["ietf-tls-server", "2019-07-02"], + ["ietf-tcp-client", "2019-07-02"], + ["onap-system", "2020-10-26"], + ["l-3vpn-profile-1-0", "2020-01-27"], + ["ietf-netconf", "2013-09-29"], + ["nts-common", "2021-06-08"], + ["mac-fc-1-0", "2020-08-26"], + ["ltp-augment-1-0", "2020-07-30"], + ["ietf-keystore", "2019-07-02"], + ["co-channel-profile-1-0", "2020-01-27"], + ["vlan-interface-1-0", "2021-01-04"], + ["ietf-yang-library", "2019-01-04"], + ["ietf-netconf-acm", "2018-02-14"], + ["ietf-x509-cert-to-name", "2014-12-10"], + ["ietf-tcp-common", "2019-07-02"], + ["tdm-container-2-0", "2020-01-23"], + ["vlan-fc-1-0", "2021-01-05"], + ["ietf-truststore", "2019-07-02"], + ["pure-ethernet-structure-2-0", "2020-01-22"], + ["ietf-system", "2014-08-06"], + ["core-model-1-4", "2019-11-27"], + ["hybrid-mw-structure-2-0", "2020-01-22"], + ["air-interface-2-0", "2020-01-21"], + ["ietf-yang-metadata", "2016-08-05"], + ["ietf-datastores", "2018-02-14"], + ["nc-notifications", "2008-07-14"], + ["ietf-netconf-nmda", "2019-01-07"], + ["ip-interface-1-0", "2020-01-24"], + ["ietf-inet-types", "2013-07-15"], + ["nts-network-function", "2021-06-18"]] \ No newline at end of file -- cgit 1.2.3-korg