'%{PACKAGES_FOLDER}/${VNFD_PKG}' Onboards ("creates") a NF Package into OSM. - Parameters: - vnfd_pkg: Name (and location) of the NF Package - overrides (optional): String with options to override the EPA and/or interface properties of the Package. This is very useful to allow to deploy e.g. non-EPA packages in EPA VIMs (or vice-versa). Valid strings are the same as in the command. E.g.: - `--override-epa`: adds EPA attributes to all VDUs. - `--override-nonepa`: removes all EPA attributes from all VDUs. - `--override-paravirt`: converts all interfaces to `PARAVIRT`. This one can be combined with the others above (e.g. '--override-nonepa --override-paravirt'). - Relevant environment variables: - OVERRIDES: If the environment variable "OVERRIDES" exists, it prevails over the value in the argument. This is often more convenient to enforce the same behaviour for every test run in a given VIM. ${overrides} OVERRIDES default=${overrides} Returns the value of an environment variable with the given name. ${overrides} = ${rc} ${stdout} osm vnfpkg-create ${overrides} ${vnfd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-create '/robot-systest/osm-packages/hackfest_basic_vnf' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_basic_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_vnf Package created: /robot-systest/osm-packages/hac... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_basic_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_vnf Package created: /robot-systest/osm-packages/hackfest_basic_vnf.tar.gz Uploading package /robot-systest/osm-packages/hackfest_basic_vnf.tar.gz afe1179d-cc49-4039-ae11-5edc2561512c ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 7 lines ${lines} = 7 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 6 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = afe1179d-cc49-4039-ae11-5edc2561512c ${id} Upload VNF package for the testsuite. azure cluster_main daily hackfest_basic regression sanity '%{PACKAGES_FOLDER}/${NSD_PKG}' Upload a NS package to OSM and return the id. ${rc} ${stdout} osm nspkg-create ${nsd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-create '/robot-systest/osm-packages/hackfest_basic_ns' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_basic_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_ns Package created: /robot-systest/osm-packages/hackf... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_basic_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_ns Package created: /robot-systest/osm-packages/hackfest_basic_ns.tar.gz 76d6b906-28ac-41c8-bc9b-947520b60b2a ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 6 lines ${lines} = 6 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 5 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = 76d6b906-28ac-41c8-bc9b-947520b60b2a ${id} Upload NS package for the testsuite. azure cluster_main daily hackfest_basic regression sanity ${id} ${NSD_NAME} %{VIM_TARGET} ${NS_NAME} ${NS_CONFIG} ${PUBLICKEY} Launch the instantation of a NS and verify in a loop that the NS instance is successfully created in a given time, and return the NS instance id. ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} Logs the given message with the given level. 300.0 ${config_attr} '${ns_config}'!='${EMPTY}' --config '${ns_config}' ${EMPTY} Sets variable based on the given condition. ${config_attr} = --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' ${sshkeys_attr} '${publickey}'!='${EMPTY}' --ssh_keys ${publickey} ${EMPTY} Sets variable based on the given condition. ${sshkeys_attr} = --ssh_keys /root/.ssh/id_rsa.pub ${config_file_attr} '${config_file}'!='${EMPTY}' --config_file '${config_file}' ${EMPTY} Sets variable based on the given condition. ${config_file_attr} = ${ns_id} ${ns_name} ${nsd} ${vim_name} ${config_attr} ${sshkeys_attr} ${config_file_attr} Launch the instantation of a NS, and return the NS instance id. ${rc} ${stdout} osm ns-create --ns_name ${ns_name} --nsd_name ${nsd} --vim_account ${vim_name} ${ns_extra_args} Runs the given command in the system and returns the RC and output. Running command 'osm ns-create --ns_name hfbasic --nsd_name hackfest_basic-ns --vim_account osm --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' --ssh_keys /root/.ssh/id_rsa.pub 2>&1'. ${rc} = 0 ${stdout} = 87515de6-a0a9-4d08-8baf-9a15f80c4e32 ${stdout} Logs the given message with the given level. 87515de6-a0a9-4d08-8baf-9a15f80c4e32 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ns_id} = 87515de6-a0a9-4d08-8baf-9a15f80c4e32 ${ns_id} Logs the given message with the given level. 87515de6-a0a9-4d08-8baf-9a15f80c4e32 ${ns_launch_max_wait_time} ${NS_LAUNCH_POL_TIME} Check For NS Instance To Configured ${ns_name} Runs the specified keyword and retries if it fails. ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfbasic" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | BUILDING | INSTANTIATING (f29d8b34-e64d-4d18-8057-54b00d6dcf91) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | BUILDING | INSTANTIATING (f29d8b34-e64d-4d18-8057-54b00d6dcf91) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | e56070bd-f419-40b3-9d84-8f82e11260c4 | hfbasic-vnf-hackfest_basic-VM-0 | ACTIVE | osm-ext=172.21.248.128 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfbasic" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | BUILDING | INSTANTIATING (f29d8b34-e64d-4d18-8057-54b00d6dcf91) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | BUILDING | INSTANTIATING (f29d8b34-e64d-4d18-8057-54b00d6dcf91) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | e56070bd-f419-40b3-9d84-8f82e11260c4 | hfbasic-vnf-hackfest_basic-VM-0 | ACTIVE | osm-ext=172.21.248.128 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfbasic" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. ${ns_name} Check if a given NS instance has not failed in the instantiation (the status should not be BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | e56070bd-f419-40b3-9d84-8f82e11260c4 | hfbasic-vnf-hackfest_basic-VM-0 | ACTIVE | osm-ext=172.21.248.128 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfbasic" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | hfbasic | 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | 2024-04-25T17:43:01 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} BROKEN Fails if ``container`` contains ``item`` one or more times. ${ns_id} ${id} = 87515de6-a0a9-4d08-8baf-9a15f80c4e32 ${NS_ID} ${id} Makes a variable available everywhere within the scope of the current suite. ${NS_ID} = 87515de6-a0a9-4d08-8baf-9a15f80c4e32 Instantiate NS for the testsuite. azure cluster_main daily hackfest_basic regression sanity ${ip_addr} ${NS_ID} ${VNF_MEMBER_INDEX} Get the mgmt IP address of a member VNF in a NS instance, and return it. ${ns_id} Verifies that the given item is not empty. Length is 36 ${vnf_member_index} Verifies that the given item is not empty. Length is 3 ${rc} ${stdout} osm vnf-list --filter member-vnf-index-ref=${vnf_member_index} | grep ${ns_id} | awk '{print $14}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm vnf-list --filter member-vnf-index-ref=vnf | grep 87515de6-a0a9-4d08-8baf-9a15f80c4e32 | awk '{print $14}' 2>&1'. ${rc} = 0 ${stdout} = 172.21.248.128 ${stdout} Logs the given message with the given level. 172.21.248.128 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ip_addr} = 172.21.248.128 ${ip_addr} Logs the given message with the given level. 172.21.248.128 ${VNF_IP_ADDR} ${ip_addr} Makes a variable available everywhere within the scope of the current suite. ${VNF_IP_ADDR} = 172.21.248.128 Get the mgmt IP address of the VNF of the NS. azure cluster_main daily hackfest_basic regression sanity ${VNF_IP_ADDR} Ping a host several times during 30sec until it succeeds or raises a timeout. ${CONNECTIVITY_MAX_WAIT_TIME} ${CONNECTIVITY_POL_TIME} Test Ping Host ${host} Runs the specified keyword and retries if it fails. ${host} Run Ping Parameters: host: IP or name of the host Execution example: Ping Test ${host} ${rc} ${stdout} ping -c 2 -W 1 ${host} Runs the given command in the system and returns the RC and output. Running command 'ping -c 2 -W 1 172.21.248.128 2>&1'. ${rc} = 0 ${stdout} = PING 172.21.248.128 (172.21.248.128) 56(84) bytes of data. 64 bytes from 172.21.248.128: icmp_seq=1 ttl=63 time=2.54 ms 64 bytes from 172.21.248.128: icmp_seq=2 ttl=63 time=0.887 ms --- 172.21.248.12... ${stdout} Logs the given message with the given level. PING 172.21.248.128 (172.21.248.128) 56(84) bytes of data. 64 bytes from 172.21.248.128: icmp_seq=1 ttl=63 time=2.54 ms 64 bytes from 172.21.248.128: icmp_seq=2 ttl=63 time=0.887 ms --- 172.21.248.128 ping statistics --- 2 packets transmitted, 2 received, 0% packet loss, time 1002ms rtt min/avg/max/mdev = 0.887/1.713/2.540/0.826 ms ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> Test that the mgmt IP address of the VNF is reachable with ping. azure cluster_main daily hackfest_basic regression sanity 30s Waiting ssh daemon to be up Pauses the test executed for the given time. Slept 30 seconds Waiting ssh daemon to be up ${VNF_IP_ADDR} ${USERNAME} ${PASSWORD} ${PRIVATEKEY} Test the SSH connection to the host with the user and credentials passed as arguments. ${host} Opens a new SSH connection to the given ``host`` and ``port``. ${username} ${password} Logs into the SSH server with the given ``username`` and ``password``. ${username} ${privatekey} Logs into the SSH server using key-based authentication. Logging into '172.21.248.128:22' as 'ubuntu'. Read output: Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-107-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage System information as of Thu Apr 25 17:44:46 UTC 2024 System load: 0.32 Processes: 105 Usage of /: 13.9% of 9.52GB Users logged in: 0 Memory usage: 19% IPv4 address for ens3: 172.21.248.128 Swap usage: 0% 1 update can be applied immediately. To see these additional updates run: apt list --upgradable The list of available updates is more than a week old. To check for new updates run: sudo apt update The programs included with the Ubuntu system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. ubuntu@hfbasic-vnf-hackfest-basic-vm-0:~$ hostname Executes ``command`` on the remote machine and returns its outputs. Executing command 'hostname'. Command exited with return code 0. Closes all open connections. Check that the VNF is accessible via SSH in its mgmt IP address. azure cluster_main daily hackfest_basic regression sanity ${NS_NAME} Delete a NS instance. ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} Logs the given message with the given level. 240.0 ${rc} ${stdout} osm ns-delete ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-delete hfbasic 2>&1'. ${rc} = 0 ${stdout} = Deletion in progress ${stdout} Logs the given message with the given level. Deletion in progress ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${ns_delete_max_wait_time} ${NS_DELETE_POL_TIME} Check For NS Instance To Be Deleted ${ns} Runs the specified keyword and retries if it fails. ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ | e56070bd-f419-40b3-9d84-8f82e11260c4 | hfbasic-vnf-hackfest_basic-VM-0 | ACTIVE | osm-ext=172.21.248.128 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep hfbasic 2>&1'. ${rc} = 0 ${stdout} = hfbasic ${rc},${stdout} Logs the given message with the given level. 0,hfbasic ${stdout} ${ns} Fails if objects are equal after converting them to strings. hfbasic == hfbasic ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep hfbasic 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${ns} Fails if objects are equal after converting them to strings. Delete NS instance. azure cleanup cluster_main daily hackfest_basic regression sanity ${NSD_NAME} Delete a NS package from OSM. ${rc} ${stdout} Run And Return Rc And Output osm nspkg-delete ${nsd_id} Runs the keyword and continues execution even if a failure occurs. osm nspkg-delete ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-delete hackfest_basic-ns 2>&1'. ${rc} = 0 ${stdout} = Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Logs the given message with the given level. Deleted ${NSD_DELETE_MAX_WAIT_TIME} ${NSD_DELETE_POL_TIME} Check For NSD ${nsd_id} Runs the specified keyword and retries if it fails. ${nsd_id} Check that a NS package exists in OSM. ${rc} ${stdout} osm nspkg-list | awk '{print $2}' | grep ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-list | awk '{print $2}' | grep hackfest_basic-ns 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${nsd_id} Fails if objects are equal after converting them to strings. Delete NS package from OSM. azure cleanup cluster_main daily hackfest_basic regression sanity ${VNFD_NAME} Delete a VNF package from OSM. ${rc} ${stdout} osm vnfpkg-delete ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-delete hackfest_basic-vnf 2>&1'. ${rc} = 0 ${stdout} = Deleted ${stdout} Logs the given message with the given level. Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${VNFD_DELETE_MAX_WAIT_TIME} ${VNFD_DELETE_POL_TIME} Check For VNFD ${vnfd_id} Runs the specified keyword and retries if it fails. ${vnfd_id} Check that a VNF package exists in OSM. ${rc} ${stdout} osm vnfpkg-list | awk '{print $2}' | grep ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-list | awk '{print $2}' | grep hackfest_basic-vnf 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${vnfd_id} Fails if objects are unequal after converting them to strings. ${stdout} ${vnfd_id} Fails if objects are equal after converting them to strings. Delete VNF package from OSM. azure cleanup cluster_main daily hackfest_basic regression sanity Suite Cleanup Runs the given keyword with the given arguments and ignores possible error. Test Suit Cleanup: Deleting Descriptor, instance and vim Delete NS ${NS_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete NSD ${NSD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete VNFD ${VNFD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. [HACKFEST-BASIC] Basic NS with a single-VDU VNF '%{PACKAGES_FOLDER}/${VNFD_PKG}' Onboards ("creates") a NF Package into OSM. - Parameters: - vnfd_pkg: Name (and location) of the NF Package - overrides (optional): String with options to override the EPA and/or interface properties of the Package. This is very useful to allow to deploy e.g. non-EPA packages in EPA VIMs (or vice-versa). Valid strings are the same as in the command. E.g.: - `--override-epa`: adds EPA attributes to all VDUs. - `--override-nonepa`: removes all EPA attributes from all VDUs. - `--override-paravirt`: converts all interfaces to `PARAVIRT`. This one can be combined with the others above (e.g. '--override-nonepa --override-paravirt'). - Relevant environment variables: - OVERRIDES: If the environment variable "OVERRIDES" exists, it prevails over the value in the argument. This is often more convenient to enforce the same behaviour for every test run in a given VIM. ${overrides} OVERRIDES default=${overrides} Returns the value of an environment variable with the given name. ${overrides} = ${rc} ${stdout} osm vnfpkg-create ${overrides} ${vnfd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-create '/robot-systest/osm-packages/hackfest_cloudinit_vnf' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_cloudinit_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_cloudinit_vnf Package created: /robot-systest/osm-pack... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_cloudinit_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_cloudinit_vnf Package created: /robot-systest/osm-packages/hackfest_cloudinit_vnf.tar.gz Uploading package /robot-systest/osm-packages/hackfest_cloudinit_vnf.tar.gz e2f7d96d-366f-4bc8-856d-f6bc5cadaf1d ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 7 lines ${lines} = 7 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 6 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = e2f7d96d-366f-4bc8-856d-f6bc5cadaf1d ${id} Upload VNF package for the testsuite. azure cluster_main daily hackfest_cloudinit regression sanity '%{PACKAGES_FOLDER}/${NSD_PKG}' Upload a NS package to OSM and return the id. ${rc} ${stdout} osm nspkg-create ${nsd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-create '/robot-systest/osm-packages/hackfest_cloudinit_ns' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_cloudinit_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_cloudinit_ns Package created: /robot-systest/osm-packag... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_cloudinit_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_cloudinit_ns Package created: /robot-systest/osm-packages/hackfest_cloudinit_ns.tar.gz 97fa9426-485d-49af-b63e-48f658facf49 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 6 lines ${lines} = 6 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 5 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = 97fa9426-485d-49af-b63e-48f658facf49 ${id} Upload NS package for the testsuite. azure cluster_main daily hackfest_cloudinit regression sanity ${id} ${NSD_NAME} %{VIM_TARGET} ${NS_NAME} ${NS_CONFIG} ${EMPTY} Launch the instantation of a NS and verify in a loop that the NS instance is successfully created in a given time, and return the NS instance id. ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} Logs the given message with the given level. 300.0 ${config_attr} '${ns_config}'!='${EMPTY}' --config '${ns_config}' ${EMPTY} Sets variable based on the given condition. ${config_attr} = --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' ${sshkeys_attr} '${publickey}'!='${EMPTY}' --ssh_keys ${publickey} ${EMPTY} Sets variable based on the given condition. ${sshkeys_attr} = ${config_file_attr} '${config_file}'!='${EMPTY}' --config_file '${config_file}' ${EMPTY} Sets variable based on the given condition. ${config_file_attr} = ${ns_id} ${ns_name} ${nsd} ${vim_name} ${config_attr} ${sshkeys_attr} ${config_file_attr} Launch the instantation of a NS, and return the NS instance id. ${rc} ${stdout} osm ns-create --ns_name ${ns_name} --nsd_name ${nsd} --vim_account ${vim_name} ${ns_extra_args} Runs the given command in the system and returns the RC and output. Running command 'osm ns-create --ns_name hfcloudinit --nsd_name hackfest_cloudinit-ns --vim_account osm --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' 2>&1'. ${rc} = 0 ${stdout} = a18e7aca-aae0-466b-ac5c-9d38ae170eb2 ${stdout} Logs the given message with the given level. a18e7aca-aae0-466b-ac5c-9d38ae170eb2 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ns_id} = a18e7aca-aae0-466b-ac5c-9d38ae170eb2 ${ns_id} Logs the given message with the given level. a18e7aca-aae0-466b-ac5c-9d38ae170eb2 ${ns_launch_max_wait_time} ${NS_LAUNCH_POL_TIME} Check For NS Instance To Configured ${ns_name} Runs the specified keyword and retries if it fails. ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfcloudinit" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | BUILDING | INSTANTIATING (b62efca1-677a-4c27-81e5-470fe55f36fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | BUILDING | INSTANTIATING (b62efca1-677a-4c27-81e5-470fe55f36fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | 4f2233fb-46df-4049-92a7-b1db6fdc7993 | hfcloudinit-vnf2-dataVM-0 | BUILD | | ubuntu20.04 | simple_requires-1-1-flv | | 5d1cfff5-24e8-4926-a00b-f1be886f3fb1 | hfcloudinit-vnf2-mgmtVM-0 | BUILD | | ubuntu20.04 | simple_requires-1-1-flv | | 15c79ad7-f646-4c12-827d-274ce7f5691d | hfcloudinit-vnf1-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.210; hfcloudinit-internal=192.168.207.76 | ubuntu20.04 | simple_requires-1-1-flv | | 46e784ea-13a5-45b3-ae59-c27517806109 | hfcloudinit-vnf1-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.207.105; osm-ext=172.21.249.32 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfcloudinit" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | BUILDING | INSTANTIATING (b62efca1-677a-4c27-81e5-470fe55f36fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | BUILDING | INSTANTIATING (b62efca1-677a-4c27-81e5-470fe55f36fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | 4f2233fb-46df-4049-92a7-b1db6fdc7993 | hfcloudinit-vnf2-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.36; hfcloudinit-internal=192.168.24.149 | ubuntu20.04 | simple_requires-1-1-flv | | 5d1cfff5-24e8-4926-a00b-f1be886f3fb1 | hfcloudinit-vnf2-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.24.210; osm-ext=172.21.248.39 | ubuntu20.04 | simple_requires-1-1-flv | | 15c79ad7-f646-4c12-827d-274ce7f5691d | hfcloudinit-vnf1-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.210; hfcloudinit-internal=192.168.207.76 | ubuntu20.04 | simple_requires-1-1-flv | | 46e784ea-13a5-45b3-ae59-c27517806109 | hfcloudinit-vnf1-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.207.105; osm-ext=172.21.249.32 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfcloudinit" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. ${ns_name} Check if a given NS instance has not failed in the instantiation (the status should not be BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | 4f2233fb-46df-4049-92a7-b1db6fdc7993 | hfcloudinit-vnf2-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.36; hfcloudinit-internal=192.168.24.149 | ubuntu20.04 | simple_requires-1-1-flv | | 5d1cfff5-24e8-4926-a00b-f1be886f3fb1 | hfcloudinit-vnf2-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.24.210; osm-ext=172.21.248.39 | ubuntu20.04 | simple_requires-1-1-flv | | 15c79ad7-f646-4c12-827d-274ce7f5691d | hfcloudinit-vnf1-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.210; hfcloudinit-internal=192.168.207.76 | ubuntu20.04 | simple_requires-1-1-flv | | 46e784ea-13a5-45b3-ae59-c27517806109 | hfcloudinit-vnf1-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.207.105; osm-ext=172.21.249.32 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="hfcloudinit" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | hfcloudinit | a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | 2024-04-25T17:45:21 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} BROKEN Fails if ``container`` contains ``item`` one or more times. ${ns_id} ${id} = a18e7aca-aae0-466b-ac5c-9d38ae170eb2 ${NS_ID} ${id} Makes a variable available everywhere within the scope of the current suite. ${NS_ID} = a18e7aca-aae0-466b-ac5c-9d38ae170eb2 Instantiate NS for the testsuite. azure cluster_main daily hackfest_cloudinit regression sanity ${ip_addr} ${NS_ID} ${VNF_MEMBER_INDEX} Get the mgmt IP address of a member VNF in a NS instance, and return it. ${ns_id} Verifies that the given item is not empty. Length is 36 ${vnf_member_index} Verifies that the given item is not empty. Length is 4 ${rc} ${stdout} osm vnf-list --filter member-vnf-index-ref=${vnf_member_index} | grep ${ns_id} | awk '{print $14}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm vnf-list --filter member-vnf-index-ref=vnf1 | grep a18e7aca-aae0-466b-ac5c-9d38ae170eb2 | awk '{print $14}' 2>&1'. ${rc} = 0 ${stdout} = 172.21.249.32 ${stdout} Logs the given message with the given level. 172.21.249.32 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ip_addr} = 172.21.249.32 ${ip_addr} Logs the given message with the given level. 172.21.249.32 ${VNF_IP_ADDR} ${ip_addr} Makes a variable available everywhere within the scope of the current suite. ${VNF_IP_ADDR} = 172.21.249.32 Get the mgmt IP address of the VNF of the NS. azure cluster_main daily hackfest_cloudinit regression sanity 30s Waiting ssh daemon to be up Pauses the test executed for the given time. Slept 30 seconds Waiting ssh daemon to be up ${VNF_IP_ADDR} ${USERNAME} ${PASSWORD} ${EMPTY} Test the SSH connection to the host with the user and credentials passed as arguments. ${host} Opens a new SSH connection to the given ``host`` and ``port``. ${username} ${password} Logs into the SSH server with the given ``username`` and ``password``. Logging into '172.21.249.32:22' as 'ubuntu'. Read output: Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-107-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage System information as of Thu Apr 25 17:47:07 UTC 2024 System load: 0.7 Processes: 105 Usage of /: 13.9% of 9.52GB Users logged in: 0 Memory usage: 19% IPv4 address for ens3: 172.21.249.32 Swap usage: 0% IPv4 address for ens4: 192.168.207.105 1 update can be applied immediately. To see these additional updates run: apt list --upgradable The list of available updates is more than a week old. To check for new updates run: sudo apt update The programs included with the Ubuntu system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. ubuntu@hfcloudinit-vnf1-mgmtvm-0:~$ ${username} ${privatekey} Logs into the SSH server using key-based authentication. hostname Executes ``command`` on the remote machine and returns its outputs. Executing command 'hostname'. Command exited with return code 0. Closes all open connections. Check that the VNF is accessible via SSH in its mgmt IP address. azure cluster_main daily hackfest_cloudinit regression sanity ${stdout} ${VNF_IP_ADDR} ${USERNAME} ${PASSWORD} ${EMPTY} sudo cat /root/helloworld.txt Execute via SSH a command in a remote host and, if the command succeeds, return the output. ${host} Opens a new SSH connection to the given ``host`` and ``port``. ${username} ${password} Logs into the SSH server with the given ``username`` and ``password``. Logging into '172.21.249.32:22' as 'ubuntu'. Read output: Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-107-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage System information as of Thu Apr 25 17:47:09 UTC 2024 System load: 0.7 Processes: 105 Usage of /: 14.1% of 9.52GB Users logged in: 0 Memory usage: 19% IPv4 address for ens3: 172.21.249.32 Swap usage: 0% IPv4 address for ens4: 192.168.207.105 1 update can be applied immediately. To see these additional updates run: apt list --upgradable The list of available updates is more than a week old. To check for new updates run: sudo apt update New release '22.04.3 LTS' available. Run 'do-release-upgrade' to upgrade to it. Last login: Thu Apr 25 17:47:08 2024 from 172.21.249.4 To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. ubuntu@hfcloudinit-vnf1-mgmtvm-0:~$ ${username} ${privatekey} Logs into the SSH server using key-based authentication. ${stdout} ${rc} ${command} return_rc=True return_stdout=True Executes ``command`` on the remote machine and returns its outputs. Executing command 'sudo cat /root/helloworld.txt'. Command exited with return code 0. ${stdout} = # My new helloworld file ${rc} = 0 ${rc} Logs the given message with the given level. 0 ${stdout} Logs the given message with the given level. # My new helloworld file Closes all open connections. ${rc} 0 Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${stdout} = # My new helloworld file ${stdout} Logs the given message with the given level. # My new helloworld file Check that the day-0 configuration via cloudinit worked as expected in the VNF. A file should exist in the VM. azure cluster_main daily hackfest_cloudinit regression sanity ${NS_NAME} Delete a NS instance. ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} Logs the given message with the given level. 240.0 ${rc} ${stdout} osm ns-delete ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-delete hfcloudinit 2>&1'. ${rc} = 0 ${stdout} = Deletion in progress ${stdout} Logs the given message with the given level. Deletion in progress ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${ns_delete_max_wait_time} ${NS_DELETE_POL_TIME} Check For NS Instance To Be Deleted ${ns} Runs the specified keyword and retries if it fails. ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ | 4f2233fb-46df-4049-92a7-b1db6fdc7993 | hfcloudinit-vnf2-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.36; hfcloudinit-internal=192.168.24.149 | ubuntu20.04 | simple_requires-1-1-flv | | 5d1cfff5-24e8-4926-a00b-f1be886f3fb1 | hfcloudinit-vnf2-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.24.210; osm-ext=172.21.248.39 | ubuntu20.04 | simple_requires-1-1-flv | | 15c79ad7-f646-4c12-827d-274ce7f5691d | hfcloudinit-vnf1-dataVM-0 | ACTIVE | hfcloudinit-datanet=192.168.57.210; hfcloudinit-internal=192.168.207.76 | ubuntu20.04 | simple_requires-1-1-flv | | 46e784ea-13a5-45b3-ae59-c27517806109 | hfcloudinit-vnf1-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.207.105; osm-ext=172.21.249.32 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------+--------+-------------------------------------------------------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep hfcloudinit 2>&1'. ${rc} = 0 ${stdout} = hfcloudinit ${rc},${stdout} Logs the given message with the given level. 0,hfcloudinit ${stdout} ${ns} Fails if objects are equal after converting them to strings. hfcloudinit == hfcloudinit ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------+--------+------------------------------------------------------------+-------------+-------------------------+ | ID ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------+--------+------------------------------------------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------+--------+------------------------------------------------------------+-------------+-------------------------+ | 4f2233fb-46df-4049-92a7-b1db6fdc7993 | hfcloudinit-vnf2-dataVM-0 | ACTIVE | hfcloudinit-internal=192.168.24.149 | ubuntu20.04 | simple_requires-1-1-flv | | 5d1cfff5-24e8-4926-a00b-f1be886f3fb1 | hfcloudinit-vnf2-mgmtVM-0 | ACTIVE | hfcloudinit-internal=192.168.24.210; osm-ext=172.21.248.39 | ubuntu20.04 | simple_requires-1-1-flv | | 15c79ad7-f646-4c12-827d-274ce7f5691d | hfcloudinit-vnf1-dataVM-0 | ACTIVE | | ubuntu20.04 | simple_requires-1-1-flv | | 46e784ea-13a5-45b3-ae59-c27517806109 | hfcloudinit-vnf1-mgmtVM-0 | ACTIVE | osm-ext=172.21.249.32 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------+--------+------------------------------------------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep hfcloudinit 2>&1'. ${rc} = 0 ${stdout} = hfcloudinit ${rc},${stdout} Logs the given message with the given level. 0,hfcloudinit ${stdout} ${ns} Fails if objects are equal after converting them to strings. hfcloudinit == hfcloudinit ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep hfcloudinit 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${ns} Fails if objects are equal after converting them to strings. Delete NS instance. azure cleanup cluster_main daily hackfest_cloudinit regression sanity ${NSD_NAME} Delete a NS package from OSM. ${rc} ${stdout} Run And Return Rc And Output osm nspkg-delete ${nsd_id} Runs the keyword and continues execution even if a failure occurs. osm nspkg-delete ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-delete hackfest_cloudinit-ns 2>&1'. ${rc} = 0 ${stdout} = Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Logs the given message with the given level. Deleted ${NSD_DELETE_MAX_WAIT_TIME} ${NSD_DELETE_POL_TIME} Check For NSD ${nsd_id} Runs the specified keyword and retries if it fails. ${nsd_id} Check that a NS package exists in OSM. ${rc} ${stdout} osm nspkg-list | awk '{print $2}' | grep ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-list | awk '{print $2}' | grep hackfest_cloudinit-ns 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${nsd_id} Fails if objects are equal after converting them to strings. Delete NS package from OSM. azure cleanup cluster_main daily hackfest_cloudinit regression sanity ${VNFD_NAME} Delete a VNF package from OSM. ${rc} ${stdout} osm vnfpkg-delete ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-delete hackfest_cloudinit-vnf 2>&1'. ${rc} = 0 ${stdout} = Deleted ${stdout} Logs the given message with the given level. Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${VNFD_DELETE_MAX_WAIT_TIME} ${VNFD_DELETE_POL_TIME} Check For VNFD ${vnfd_id} Runs the specified keyword and retries if it fails. ${vnfd_id} Check that a VNF package exists in OSM. ${rc} ${stdout} osm vnfpkg-list | awk '{print $2}' | grep ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-list | awk '{print $2}' | grep hackfest_cloudinit-vnf 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${vnfd_id} Fails if objects are unequal after converting them to strings. ${stdout} ${vnfd_id} Fails if objects are equal after converting them to strings. Delete VNF package from OSM. azure cleanup cluster_main daily hackfest_cloudinit regression sanity Suite Cleanup Runs the given keyword with the given arguments and ignores possible error. Test Suit Cleanup: Deleting Descriptor, instance and vim Delete NS ${NS_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete NSD ${NSD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete VNFD ${VNFD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. [HACKFEST-CLOUDINIT] Basic NS with two multi-VDU VNF with cloudinit '%{PACKAGES_FOLDER}/${VNFD_PKG}' Onboards ("creates") a NF Package into OSM. - Parameters: - vnfd_pkg: Name (and location) of the NF Package - overrides (optional): String with options to override the EPA and/or interface properties of the Package. This is very useful to allow to deploy e.g. non-EPA packages in EPA VIMs (or vice-versa). Valid strings are the same as in the command. E.g.: - `--override-epa`: adds EPA attributes to all VDUs. - `--override-nonepa`: removes all EPA attributes from all VDUs. - `--override-paravirt`: converts all interfaces to `PARAVIRT`. This one can be combined with the others above (e.g. '--override-nonepa --override-paravirt'). - Relevant environment variables: - OVERRIDES: If the environment variable "OVERRIDES" exists, it prevails over the value in the argument. This is often more convenient to enforce the same behaviour for every test run in a given VIM. ${overrides} OVERRIDES default=${overrides} Returns the value of an environment variable with the given name. ${overrides} = ${rc} ${stdout} osm vnfpkg-create ${overrides} ${vnfd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-create '/robot-systest/osm-packages/openldap_knf' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/openldap_knf Validation OK List of charms in the descriptor: set() Adding File: openldap_knf Package created: /robot-systest/osm-packages/openldap_knf.ta... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/openldap_knf Validation OK List of charms in the descriptor: set() Adding File: openldap_knf Package created: /robot-systest/osm-packages/openldap_knf.tar.gz Uploading package /robot-systest/osm-packages/openldap_knf.tar.gz d671222a-6556-4e85-9070-927030bc2d43 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 7 lines ${lines} = 7 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 6 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = d671222a-6556-4e85-9070-927030bc2d43 ${id} Upload NF package for the testsuite. azure cluster_k8s daily k8s_04 prepare regression sanity '%{PACKAGES_FOLDER}/${NSD_PKG}' Upload a NS package to OSM and return the id. ${rc} ${stdout} osm nspkg-create ${nsd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-create '/robot-systest/osm-packages/openldap_ns' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/openldap_ns Validation OK List of charms in the descriptor: set() Adding File: openldap_ns Package created: /robot-systest/osm-packages/openldap_ns.tar.g... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/openldap_ns Validation OK List of charms in the descriptor: set() Adding File: openldap_ns Package created: /robot-systest/osm-packages/openldap_ns.tar.gz cb2fbd2b-e803-4eb8-8312-77bbca8ac62e ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 6 lines ${lines} = 6 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 5 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = cb2fbd2b-e803-4eb8-8312-77bbca8ac62e ${id} Upload NS package for the testsuite. azure cluster_k8s daily k8s_04 prepare regression sanity ${id} ${NSD_NAME} %{VIM_TARGET} ${NS_NAME} ${NS_CONFIG} ${PUBLICKEY} Launch the instantation of a NS and verify in a loop that the NS instance is successfully created in a given time, and return the NS instance id. ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} Logs the given message with the given level. 300.0 ${config_attr} '${ns_config}'!='${EMPTY}' --config '${ns_config}' ${EMPTY} Sets variable based on the given condition. ${config_attr} = --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext}], additionalParamsForVnf: [ {member-vnf-index: openldap, additionalParamsForKdu: [ {kdu_name: ldap, additionalParams: {service: {type: Load... ${sshkeys_attr} '${publickey}'!='${EMPTY}' --ssh_keys ${publickey} ${EMPTY} Sets variable based on the given condition. ${sshkeys_attr} = ${config_file_attr} '${config_file}'!='${EMPTY}' --config_file '${config_file}' ${EMPTY} Sets variable based on the given condition. ${config_file_attr} = ${ns_id} ${ns_name} ${nsd} ${vim_name} ${config_attr} ${sshkeys_attr} ${config_file_attr} Launch the instantation of a NS, and return the NS instance id. ${rc} ${stdout} osm ns-create --ns_name ${ns_name} --nsd_name ${nsd} --vim_account ${vim_name} ${ns_extra_args} Runs the given command in the system and returns the RC and output. Running command 'osm ns-create --ns_name ldap --nsd_name openldap_ns --vim_account osm --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext}], additionalParamsForVnf: [ {member-vnf-index: openldap, additionalParamsForKdu: [ {kdu_name: ldap, additionalParams: {service: {type: LoadBalancer }, adminPassword: admin}} ] } ] }' 2>&1'. ${rc} = 0 ${stdout} = eef36a6e-ab70-4359-ad40-a392036e8875 ${stdout} Logs the given message with the given level. eef36a6e-ab70-4359-ad40-a392036e8875 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ns_id} = eef36a6e-ab70-4359-ad40-a392036e8875 ${ns_id} Logs the given message with the given level. eef36a6e-ab70-4359-ad40-a392036e8875 ${ns_launch_max_wait_time} ${NS_LAUNCH_POL_TIME} Check For NS Instance To Configured ${ns_name} Runs the specified keyword and retries if it fails. ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="ldap" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | BUILDING | INSTANTIATING (fbc0b5e4-1ecb-49e8-aa97-34eac95dfa2f) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | BUILDING | INSTANTIATING (fbc0b5e4-1ecb-49e8-aa97-34eac95dfa2f) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="ldap" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | BUILDING | INSTANTIATING (fbc0b5e4-1ecb-49e8-aa97-34eac95dfa2f) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | BUILDING | INSTANTIATING (fbc0b5e4-1ecb-49e8-aa97-34eac95dfa2f) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="ldap" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. ${ns_name} Check if a given NS instance has not failed in the instantiation (the status should not be BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="ldap" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ldap | eef36a6e-ab70-4359-ad40-a392036e8875 | 2024-04-25T17:48:01 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} BROKEN Fails if ``container`` contains ``item`` one or more times. ${ns_id} ${id} = eef36a6e-ab70-4359-ad40-a392036e8875 ${id} Logs the given message with the given level. eef36a6e-ab70-4359-ad40-a392036e8875 Instantiate NS for the testsuite. azure cluster_k8s daily k8s_04 prepare regression sanity ${id} ${NS_NAME} Get the NS instance ID from a NS instance name passed as argument, and return it. ${ns_name} Verifies that the given item is not empty. Length is 4 ${rc} ${stdout} osm ns-list | grep ${ns_name} | awk '{print $4}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | grep ldap | awk '{print $4}' 2>&1'. ${rc} = 0 ${stdout} = eef36a6e-ab70-4359-ad40-a392036e8875 ${stdout} Logs the given message with the given level. eef36a6e-ab70-4359-ad40-a392036e8875 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Verifies that the given item is not empty. Length is 36 ${stdout} ${id} = eef36a6e-ab70-4359-ad40-a392036e8875 ${NS_ID} ${id} Makes a variable available everywhere within the scope of the current suite. ${NS_ID} = eef36a6e-ab70-4359-ad40-a392036e8875 Retrieve NS instance id to be used later on. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_ID} msg=Network service instance is not available Fails unless the given variable exists within the current scope. @{vnfr_list} ${NS_ID} Return a list with the IDs of the VNF records of a NS instance. ${ns_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm vnf-list --ns ${ns_id} | grep ${ns_id} | awk '{print $2}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm vnf-list --ns eef36a6e-ab70-4359-ad40-a392036e8875 | grep eef36a6e-ab70-4359-ad40-a392036e8875 | awk '{print $2}' 2>&1'. ${rc} = 0 ${stdout} = b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> @{vdur} ${stdout} Splits the ``string`` using ``separator`` as a delimiter string. @{vdur} = [ b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a ] @{vdur} @{vnfr_list} = [ b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a ] ${vnfr_list} Logs the length and contents of the ``list`` using given ``level``. List has one item: b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a ${VNF_ID} ${vnfr_list}[0] Makes a variable available everywhere within the scope of the current suite. ${VNF_ID} = b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a Retrieve NF instance id to be used later on. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_ID} msg=Network service instance is not available Fails unless the given variable exists within the current scope. ${ns_op_id} ${NS_NAME} ${UPGRADE_ACTION} ${VNF_MEMBER_INDEX} ${KDU_NAME} replicaCount=${REPLICA_COUNT} Execute an action over the desired K8s NS. Parameters are given to this function in key=value format (one argument per key/value pair). Return the ID of the operation associated to the executed action. Examples of execution: ${ns_op_id}= Execute NS Action ${ns_name} ${ns_action} ${vnf_member_index} ${ns_op_id}= Execute NS Action ${ns_name} ${ns_action} ${vnf_member_index} ${param1}=${value1} ${param2}=${value2} ${params} ${EMPTY} Returns the given values which can then be assigned to a variables. ${params} = ${param} @{action_params} replicaCount=3 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = replicaCount=3 ${param_name} = replicaCount ${param_value} = 3 ${match},${param_name},${param_value} Logs the given message with the given level. replicaCount=3,replicaCount,3 ${params} SEPARATOR= ${params} "${param_name}":"${param_value}", Catenates the given items together and returns the resulted string. ${params} = "replicaCount":"3", ${osm_ns_action_command} osm ns-action --action_name ${ns_action} --vnf_name ${vnf_member_index} --kdu_name ${kdu_name} Returns the given values which can then be assigned to a variables. ${osm_ns_action_command} = osm ns-action --action_name upgrade --vnf_name openldap --kdu_name ldap ${osm_ns_action_command} ${osm_ns_action_command} --params '{${params}}' Catenates the given items together and returns the resulted string. ${osm_ns_action_command} = osm ns-action --action_name upgrade --vnf_name openldap --kdu_name ldap --params '{"replicaCount":"3",}' ${osm_ns_action_command} ${osm_ns_action_command} Returns the given values which can then be assigned to a variables. ${osm_ns_action_command} ${osm_ns_action_command} ${ns_name} Catenates the given items together and returns the resulted string. ${osm_ns_action_command} = osm ns-action --action_name upgrade --vnf_name openldap --kdu_name ldap --params '{"replicaCount":"3",}' ldap ${rc} ${stdout} ${osm_ns_action_command} Runs the given command in the system and returns the RC and output. Running command 'osm ns-action --action_name upgrade --vnf_name openldap --kdu_name ldap --params '{"replicaCount":"3",}' ldap 2>&1'. ${rc} = 0 ${stdout} = 06b09079-02da-40d3-9038-debe29aa9936 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${NS_ACTION_MAX_WAIT_TIME} ${NS_ACTION_POL_TIME} Check For NS Operation Ended ${stdout} Runs the specified keyword and retries if it fails. ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show 06b09079-02da-40d3-9038-debe29aa9936 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = PROCESSING ${stdout} Logs the given message with the given level. PROCESSING ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. Timeout waiting for ns-action with id 06b09079-02da-40d3-9038-debe29aa9936 ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show 06b09079-02da-40d3-9038-debe29aa9936 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = PROCESSING ${stdout} Logs the given message with the given level. PROCESSING ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. Timeout waiting for ns-action with id 06b09079-02da-40d3-9038-debe29aa9936 ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show 06b09079-02da-40d3-9038-debe29aa9936 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = PROCESSING ${stdout} Logs the given message with the given level. PROCESSING ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. Timeout waiting for ns-action with id 06b09079-02da-40d3-9038-debe29aa9936 ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show 06b09079-02da-40d3-9038-debe29aa9936 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = COMPLETED ${stdout} Logs the given message with the given level. COMPLETED ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. ${stdout} Check wheter the status of the desired operation is "COMPLETED" or not. ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show 06b09079-02da-40d3-9038-debe29aa9936 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = COMPLETED ${stdout} Logs the given message with the given level. COMPLETED ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} COMPLETED msg=The ns-action with id ${ns_operation_id} was not completed values=False Fails if ``container`` does not contain ``item`` one or more times. ${stdout} ${ns_op_id} = 06b09079-02da-40d3-9038-debe29aa9936 ${ns_op_id} Logs the given message with the given level. 06b09079-02da-40d3-9038-debe29aa9936 Perform OSM action to upgrade the number of replicas of a deployment in the CNF. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_ID} msg=Network service instance is not available Fails unless the given variable exists within the current scope. ${count} ${VNF_ID} ${KDU_NAME} Return the number of KDU replicas (empty if none) of a VNF instance. ${vnf_id} Verifies that the given item is not empty. Length is 36 ${kdu_name} Verifies that the given item is not empty. Length is 4 ${rc} ${stdout} osm vnf-show ${vnf_id} --kdu ${kdu_name} | yq -r .config.replicaCount Runs the given command in the system and returns the RC and output. Running command 'osm vnf-show b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a --kdu ldap | yq -r .config.replicaCount 2>&1'. ${rc} = 0 ${stdout} = 3 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${return} '${stdout}' == 'null' ${EMPTY} ${stdout} Sets variable based on the given condition. ${return} = 3 ${return} ${count} = 3 ${count} Logs the given message with the given level. 3 ${count} ${REPLICA_COUNT} Fails if objects are unequal after converting them to integers. Check that the number of replicas after the upgrade is the expected one. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_ID} msg=Network service instance is not available Fails unless the given variable exists within the current scope. ${ns_op_id} ${NS_NAME} ${ROLLBACK_ACTION} ${VNF_MEMBER_INDEX} ${KDU_NAME} Execute an action over the desired K8s NS. Parameters are given to this function in key=value format (one argument per key/value pair). Return the ID of the operation associated to the executed action. Examples of execution: ${ns_op_id}= Execute NS Action ${ns_name} ${ns_action} ${vnf_member_index} ${ns_op_id}= Execute NS Action ${ns_name} ${ns_action} ${vnf_member_index} ${param1}=${value1} ${param2}=${value2} ${params} ${EMPTY} Returns the given values which can then be assigned to a variables. ${params} = ${param} @{action_params} ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match},${param_name},${param_value} Logs the given message with the given level. ${params} SEPARATOR= ${params} "${param_name}":"${param_value}", Catenates the given items together and returns the resulted string. ${osm_ns_action_command} osm ns-action --action_name ${ns_action} --vnf_name ${vnf_member_index} --kdu_name ${kdu_name} Returns the given values which can then be assigned to a variables. ${osm_ns_action_command} = osm ns-action --action_name rollback --vnf_name openldap --kdu_name ldap ${osm_ns_action_command} ${osm_ns_action_command} --params '{${params}}' Catenates the given items together and returns the resulted string. ${osm_ns_action_command} ${osm_ns_action_command} Returns the given values which can then be assigned to a variables. ${osm_ns_action_command} = osm ns-action --action_name rollback --vnf_name openldap --kdu_name ldap ${osm_ns_action_command} ${osm_ns_action_command} ${ns_name} Catenates the given items together and returns the resulted string. ${osm_ns_action_command} = osm ns-action --action_name rollback --vnf_name openldap --kdu_name ldap ldap ${rc} ${stdout} ${osm_ns_action_command} Runs the given command in the system and returns the RC and output. Running command 'osm ns-action --action_name rollback --vnf_name openldap --kdu_name ldap ldap 2>&1'. ${rc} = 0 ${stdout} = bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${NS_ACTION_MAX_WAIT_TIME} ${NS_ACTION_POL_TIME} Check For NS Operation Ended ${stdout} Runs the specified keyword and retries if it fails. ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = PROCESSING ${stdout} Logs the given message with the given level. PROCESSING ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. Timeout waiting for ns-action with id bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 ${stdout} Check wheter the status of the desired operation is "FAILED" or "COMPLETED". ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = COMPLETED ${stdout} Logs the given message with the given level. COMPLETED ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} FAILED COMPLETED msg=Timeout waiting for ns-action with id ${ns_operation_id} values=False Fails if ``container`` does not contain any of the ``*items``. ${stdout} Check wheter the status of the desired operation is "COMPLETED" or not. ${ns_operation_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm ns-op-show ${ns_operation_id} --literal | yq -r .operationState Runs the given command in the system and returns the RC and output. Running command 'osm ns-op-show bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 --literal | yq -r .operationState 2>&1'. ${rc} = 0 ${stdout} = COMPLETED ${stdout} Logs the given message with the given level. COMPLETED ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} COMPLETED msg=The ns-action with id ${ns_operation_id} was not completed values=False Fails if ``container`` does not contain ``item`` one or more times. ${stdout} ${ns_op_id} = bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 ${ns_op_id} Logs the given message with the given level. bb98b5dc-1d1e-43ac-8c06-8e5ef1634b15 Perform OSM action to rollback the previous upgrade of the CNF. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_ID} msg=Network service instance is not available Fails unless the given variable exists within the current scope. ${count} ${VNF_ID} ${KDU_NAME} Return the number of KDU replicas (empty if none) of a VNF instance. ${vnf_id} Verifies that the given item is not empty. Length is 36 ${kdu_name} Verifies that the given item is not empty. Length is 4 ${rc} ${stdout} osm vnf-show ${vnf_id} --kdu ${kdu_name} | yq -r .config.replicaCount Runs the given command in the system and returns the RC and output. Running command 'osm vnf-show b04e99c3-4cf1-4aa8-970e-5f23f69e9a8a --kdu ldap | yq -r .config.replicaCount 2>&1'. ${rc} = 0 ${stdout} = null ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${return} '${stdout}' == 'null' ${EMPTY} ${stdout} Sets variable based on the given condition. ${return} = ${return} ${count} = ${count} Logs the given message with the given level. ${count} Verifies that the given item is empty. Length is 0 Check that the number of replcias after the rollback is the expected one. azure cluster_k8s daily k8s_04 regression sanity verify ${NS_NAME} Delete a NS instance. ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} Logs the given message with the given level. 240.0 ${rc} ${stdout} osm ns-delete ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-delete ldap 2>&1'. ${rc} = 0 ${stdout} = Deletion in progress ${stdout} Logs the given message with the given level. Deletion in progress ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${ns_delete_max_wait_time} ${NS_DELETE_POL_TIME} Check For NS Instance To Be Deleted ${ns} Runs the specified keyword and retries if it fails. ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep ldap 2>&1'. ${rc} = 0 ${stdout} = ldap ${rc},${stdout} Logs the given message with the given level. 0,ldap ${stdout} ${ns} Fails if objects are equal after converting them to strings. ldap == ldap ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep ldap 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${ns} Fails if objects are equal after converting them to strings. Delete NS instance. azure cleanup cluster_k8s daily k8s_04 regression sanity ${NSD_NAME} Delete a NS package from OSM. ${rc} ${stdout} Run And Return Rc And Output osm nspkg-delete ${nsd_id} Runs the keyword and continues execution even if a failure occurs. osm nspkg-delete ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-delete openldap_ns 2>&1'. ${rc} = 0 ${stdout} = Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Logs the given message with the given level. Deleted ${NSD_DELETE_MAX_WAIT_TIME} ${NSD_DELETE_POL_TIME} Check For NSD ${nsd_id} Runs the specified keyword and retries if it fails. ${nsd_id} Check that a NS package exists in OSM. ${rc} ${stdout} osm nspkg-list | awk '{print $2}' | grep ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-list | awk '{print $2}' | grep openldap_ns 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${nsd_id} Fails if objects are equal after converting them to strings. Delete NS package from OSM. azure cleanup cluster_k8s daily k8s_04 regression sanity ${VNFD_NAME} Delete a VNF package from OSM. ${rc} ${stdout} osm vnfpkg-delete ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-delete openldap_knf 2>&1'. ${rc} = 0 ${stdout} = Deleted ${stdout} Logs the given message with the given level. Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${VNFD_DELETE_MAX_WAIT_TIME} ${VNFD_DELETE_POL_TIME} Check For VNFD ${vnfd_id} Runs the specified keyword and retries if it fails. ${vnfd_id} Check that a VNF package exists in OSM. ${rc} ${stdout} osm vnfpkg-list | awk '{print $2}' | grep ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-list | awk '{print $2}' | grep openldap_knf 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${vnfd_id} Fails if objects are unequal after converting them to strings. ${stdout} ${vnfd_id} Fails if objects are equal after converting them to strings. Delete NF package from OSM. azure cleanup cluster_k8s daily k8s_04 regression sanity Suite Cleanup Runs the given keyword with the given arguments and ignores possible error. Test Suit Cleanup: Deleting Descriptor, instance and vim Delete NS ${NS_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete NSD ${NSD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete VNFD ${VNFD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. [K8s-04] Openldap Helm chart. Suite Preparation Runs the given keyword with the given arguments and ignores possible error. Test Suite Preparation: Setting Prometheus Testsuite Variables Set Testsuite Prometheus Variables to be used in subsequent test cases ${local_prometheus_host} OSM_HOSTNAME Returns the value of an environment variable with the given name. ${PROMETHEUS_HOST} ${local_prometheus_host} Makes a variable available everywhere within the scope of the current suite. ${PROMETHEUS_HOST} 9091 Makes a variable available everywhere within the scope of the current suite. Invalid IF condition: Evaluating expression '172.21.248.101 == 'UNKNOWN'' failed: SyntaxError: invalid syntax (<string>, line 1) Variables in the original expression '${PROMETHEUS_HOST} == 'UNKNOWN'' were resolved before the expression was evaluated. Try using '$PROMETHEUS_HOST == 'UNKNOWN'' syntax to avoid that. See Evaluating Expressions appendix in Robot Framework User Guide for more details. ${PROMETHEUS_PORT} Logs the given message with the given level. ${PROMETHEUS_HOST} Logs the given message with the given level. ${PROMETHEUS_USER} Logs the given message with the given level. ${PROMETHEUS_PASSWORD} Logs the given message with the given level. '%{PACKAGES_FOLDER}/${VNFD_PKG}' Onboards ("creates") a NF Package into OSM. - Parameters: - vnfd_pkg: Name (and location) of the NF Package - overrides (optional): String with options to override the EPA and/or interface properties of the Package. This is very useful to allow to deploy e.g. non-EPA packages in EPA VIMs (or vice-versa). Valid strings are the same as in the command. E.g.: - `--override-epa`: adds EPA attributes to all VDUs. - `--override-nonepa`: removes all EPA attributes from all VDUs. - `--override-paravirt`: converts all interfaces to `PARAVIRT`. This one can be combined with the others above (e.g. '--override-nonepa --override-paravirt'). - Relevant environment variables: - OVERRIDES: If the environment variable "OVERRIDES" exists, it prevails over the value in the argument. This is often more convenient to enforce the same behaviour for every test run in a given VIM. ${overrides} OVERRIDES default=${overrides} Returns the value of an environment variable with the given name. ${overrides} = ${rc} ${stdout} osm vnfpkg-create ${overrides} ${vnfd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-create '/robot-systest/osm-packages/hackfest_basic_metrics_vnf' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_basic_metrics_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_metrics_vnf Package created: /robot-systest/... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_basic_metrics_vnf Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_metrics_vnf Package created: /robot-systest/osm-packages/hackfest_basic_metrics_vnf.tar.gz Uploading package /robot-systest/osm-packages/hackfest_basic_metrics_vnf.tar.gz 51d15e1d-857d-4310-a6e1-d0103c30e6fa ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 7 lines ${lines} = 7 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 6 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = 51d15e1d-857d-4310-a6e1-d0103c30e6fa ${id} Upload VNF package for the testsuite. azure cluster_sa daily regression sa_02 sanity ${rc} ${stdout} osm vnfpkg-show ${VNFD_NAME} --literal | yq -r '.df[0]."scaling-aspect"[0]."scaling-policy"[0]."scaling-criteria"[0]."scale-out-threshold"' Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-show hackfest_basic_metrics-vnf --literal | yq -r '.df[0]."scaling-aspect"[0]."scaling-policy"[0]."scaling-criteria"[0]."scale-out-threshold"' 2>&1'. ${rc} = 0 ${stdout} = 60.0000000000 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${scaleout_threshold} ${stdout} Converts the given item to a floating point number. ${scaleout_threshold} = 60.0 ${METRIC_THRESHOLD} ${scaleout_threshold} Makes a variable available everywhere within the scope of the current suite. ${METRIC_THRESHOLD} = 60.0 ${METRIC_THRESHOLD} Logs the given message with the given level. 60.0 ${rc} ${stdout} osm vnfpkg-show ${VNFD_NAME} --literal | yq -r '.df[0]."scaling-aspect"[0]."scaling-policy"[0]."threshold-time"' Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-show hackfest_basic_metrics-vnf --literal | yq -r '.df[0]."scaling-aspect"[0]."scaling-policy"[0]."threshold-time"' 2>&1'. ${rc} = 0 ${stdout} = 1 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${threshold_time_value} ${stdout} Converts the given item to a floating point number. ${threshold_time_value} = 1.0 ${THRESHOLD_TIME} ${threshold_time_value} Makes a variable available everywhere within the scope of the current suite. ${THRESHOLD_TIME} = 1.0 ${THRESHOLD_TIME} Logs the given message with the given level. 1.0 Read metric threshold and threshold time from VNF descriptor. azure cluster_sa daily regression sa_02 sanity '%{PACKAGES_FOLDER}/${NSD_PKG}' Upload a NS package to OSM and return the id. ${rc} ${stdout} osm nspkg-create ${nsd_pkg} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-create '/robot-systest/osm-packages/hackfest_basic_metrics_ns' 2>&1'. ${rc} = 0 ${stdout} = Validating package /robot-systest/osm-packages/hackfest_basic_metrics_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_metrics_ns Package created: /robot-systest/os... ${stdout} Logs the given message with the given level. Validating package /robot-systest/osm-packages/hackfest_basic_metrics_ns Validation OK List of charms in the descriptor: set() Adding File: hackfest_basic_metrics_ns Package created: /robot-systest/osm-packages/hackfest_basic_metrics_ns.tar.gz 2d5ac095-06cf-4bf0-935e-cb4538485b4e ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${lines} ${stdout} Returns and logs the number of lines in the given string. 6 lines ${lines} = 6 ${last} ${lines} - 1 Evaluates the given expression in Python and returns the result. ${last} = 5 ${id} ${stdout} ${last} Returns the specified line from the given ``string``. ${id} = 2d5ac095-06cf-4bf0-935e-cb4538485b4e ${id} Upload NS package for the testsuite. azure cluster_sa daily regression sa_02 sanity ${id} ${NSD_NAME} %{VIM_TARGET} ${NS_NAME} ${NS_CONFIG} ${PUBLICKEY} Launch the instantation of a NS and verify in a loop that the NS instance is successfully created in a given time, and return the NS instance id. ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} ${ns_launch_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_launch_max_wait_time} = 300.0 ${ns_launch_max_wait_time} Logs the given message with the given level. 300.0 ${config_attr} '${ns_config}'!='${EMPTY}' --config '${ns_config}' ${EMPTY} Sets variable based on the given condition. ${config_attr} = --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' ${sshkeys_attr} '${publickey}'!='${EMPTY}' --ssh_keys ${publickey} ${EMPTY} Sets variable based on the given condition. ${sshkeys_attr} = --ssh_keys /root/.ssh/id_rsa.pub ${config_file_attr} '${config_file}'!='${EMPTY}' --config_file '${config_file}' ${EMPTY} Sets variable based on the given condition. ${config_file_attr} = ${ns_id} ${ns_name} ${nsd} ${vim_name} ${config_attr} ${sshkeys_attr} ${config_file_attr} Launch the instantation of a NS, and return the NS instance id. ${rc} ${stdout} osm ns-create --ns_name ${ns_name} --nsd_name ${nsd} --vim_account ${vim_name} ${ns_extra_args} Runs the given command in the system and returns the RC and output. Running command 'osm ns-create --ns_name sa_02 --nsd_name hackfest_basic-ns-metrics --vim_account osm --config '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ] }' --ssh_keys /root/.ssh/id_rsa.pub 2>&1'. ${rc} = 0 ${stdout} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${stdout} Logs the given message with the given level. 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ns_id} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${ns_id} Logs the given message with the given level. 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${ns_launch_max_wait_time} ${NS_LAUNCH_POL_TIME} Check For NS Instance To Configured ${ns_name} Runs the specified keyword and retries if it fails. ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="sa_02" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | sa_02 | 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | 2024-04-25T17:51:16 | BUILDING | INSTANTIATING (8635ea3f-9752-4440-bc08-62c72d5297fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. '+------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ | sa_02 | 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | 2024-04-25T17:51:16 | BUILDING | INSTANTIATING (8635ea3f-9752-4440-bc08-62c72d5297fa) | N/A | +------------------+--------------------------------------+---------------------+----------+------------------------------------------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID"' does not contain any of 'READY' or 'BROKEN' ${ns_name} Check if a given NS instance has completed the instantiation, no matter if it succeeded (the status should be READY or BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | 8f63e2ab-1610-4a2d-a9a0-36d728cdb91b | sa_02-vnf-hackfest_basic_metrics-VM-0 | ACTIVE | osm-ext=172.21.249.34 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="sa_02" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | sa_02 | 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | 2024-04-25T17:51:16 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} READY BROKEN Fails if ``container`` does not contain any of the ``*items``. ${ns_name} Check if a given NS instance has not failed in the instantiation (the status should not be BROKEN). ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | 8f63e2ab-1610-4a2d-a9a0-36d728cdb91b | sa_02-vnf-hackfest_basic_metrics-VM-0 | ACTIVE | osm-ext=172.21.249.34 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list --filter name="${ns_name}" Runs the given command in the system and returns the RC and output. Running command 'osm ns-list --filter name="sa_02" 2>&1'. ${rc} = 0 ${stdout} = +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date ... ${rc},${stdout} Logs the given message with the given level. 0,+------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | ns instance name | id | date | ns state | current operation | error details | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ | sa_02 | 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | 2024-04-25T17:51:16 | READY | IDLE (None) | N/A | +------------------+--------------------------------------+---------------------+----------+-------------------+---------------+ To get the history of all operations over a NS, run "osm ns-op-list NS_ID" For more details on the current operation, run "osm ns-op-show OPERATION_ID" ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} BROKEN Fails if ``container`` contains ``item`` one or more times. ${ns_id} ${id} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${NS_ID} ${id} Makes a variable available everywhere within the scope of the current suite. ${NS_ID} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 Instantiate the NS for the testsuite. azure cluster_sa daily regression sa_02 sanity @{vnfr_list} ${NS_ID} Return a list with the IDs of the VNF records of a NS instance. ${ns_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm vnf-list --ns ${ns_id} | grep ${ns_id} | awk '{print $2}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm vnf-list --ns 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | grep 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | awk '{print $2}' 2>&1'. ${rc} = 0 ${stdout} = 09e67741-cefa-44ca-94bb-8f5a44ec300a ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> @{vdur} ${stdout} Splits the ``string`` using ``separator`` as a delimiter string. @{vdur} = [ 09e67741-cefa-44ca-94bb-8f5a44ec300a ] @{vdur} @{vnfr_list} = [ 09e67741-cefa-44ca-94bb-8f5a44ec300a ] ${vnfr_list} Logs the length and contents of the ``list`` using given ``level``. List has one item: 09e67741-cefa-44ca-94bb-8f5a44ec300a ${VNF_ID} ${vnfr_list}[0] Makes a variable available everywhere within the scope of the current suite. ${VNF_ID} = 09e67741-cefa-44ca-94bb-8f5a44ec300a Retrieve VNF instance id to be used later on. azure cluster_sa daily regression sa_02 sanity ${ip_addr} ${NS_ID} ${VNF_MEMBER_INDEX} Get the mgmt IP address of a member VNF in a NS instance, and return it. ${ns_id} Verifies that the given item is not empty. Length is 36 ${vnf_member_index} Verifies that the given item is not empty. Length is 3 ${rc} ${stdout} osm vnf-list --filter member-vnf-index-ref=${vnf_member_index} | grep ${ns_id} | awk '{print $14}' 2>&1 Runs the given command in the system and returns the RC and output. Running command 'osm vnf-list --filter member-vnf-index-ref=vnf | grep 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 | awk '{print $14}' 2>&1'. ${rc} = 0 ${stdout} = 172.21.249.34 ${stdout} Logs the given message with the given level. 172.21.249.34 ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} ${ip_addr} = 172.21.249.34 ${ip_addr} Logs the given message with the given level. 172.21.249.34 ${VNF_IP_ADDR} ${ip_addr} Makes a variable available everywhere within the scope of the current suite. ${VNF_IP_ADDR} = 172.21.249.34 Get the mgmt IP address of the VNF to be used in later tests. azure cluster_sa daily regression sa_02 sanity ${PROMETHEUS_POLL_RETRIES} msg=Metric polling retries is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_POLL_TIMEOUT} msg=Metric polling timeout is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_POLL_RETRIES} ${PROMETHEUS_POLL_TIMEOUT} Get Metric ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Runs the specified keyword and retries if it fails. ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61d4a60>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:51:58 GMT', 'Content-Length': '87'} body={"status":"success","data":{"resultType":"vector","result":[]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': []}} ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [] ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 0 ${results} = 0 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> Metric osm_cpu_utilization not found 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. ${result_list[0]["value"][1]} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f0460>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:52:58 GMT', 'Content-Length': '87'} body={"status":"success","data":{"resultType":"vector","result":[]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': []}} ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [] ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 0 ${results} = 0 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> Metric osm_cpu_utilization not found 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. ${result_list[0]["value"][1]} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f2860>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:53:58 GMT', 'Content-Length': '87'} body={"status":"success","data":{"resultType":"vector","result":[]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': []}} ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [] ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 0 ${results} = 0 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> Metric osm_cpu_utilization not found 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. ${result_list[0]["value"][1]} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f22c0>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:54:58 GMT', 'Content-Length': '87'} body={"status":"success","data":{"resultType":"vector","result":[]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': []}} ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [] ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 0 ${results} = 0 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> Metric osm_cpu_utilization not found 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. ${result_list[0]["value"][1]} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad623cdf0>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:55:58 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714067758.285,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' Fails the test with the given message and optionally alters its tags. msg=The metric '${METRIC_NAME}' value is higher than '${METRIC_THRESHOLD}' before scaling Fails the test with the given message and optionally alters its tags. Get from Prometheus the VIM metric associated to the VNF auto-scaling group. azure cluster_sa daily regression sa_02 sanity ${PRIVATEKEY} msg=SSH private key not available Fails unless the given variable exists within the current scope. ${VNF_IP_ADDR} ${USERNAME} ${PASSWORD} ${PRIVATEKEY} for i in {1..9}; do yes &> /dev/null & done Execute via SSH a command in a remote host and, if the command succeeds, return the output. ${host} Opens a new SSH connection to the given ``host`` and ``port``. ${username} ${password} Logs into the SSH server with the given ``username`` and ``password``. Logging into '172.21.249.34:22' as 'ubuntu'. Read output: Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-107-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage System information as of Thu Apr 25 17:55:58 UTC 2024 System load: 0.67 Processes: 107 Usage of /: 14.1% of 9.52GB Users logged in: 0 Memory usage: 19% IPv4 address for ens3: 172.21.249.34 Swap usage: 0% 1 update can be applied immediately. To see these additional updates run: apt list --upgradable The list of available updates is more than a week old. To check for new updates run: sudo apt update The programs included with the Ubuntu system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. ubuntu@sa-02-vnf-hackfest-basic-metrics-vm-0:~$ ${username} ${privatekey} Logs into the SSH server using key-based authentication. ${stdout} ${rc} ${command} return_rc=True return_stdout=True Executes ``command`` on the remote machine and returns its outputs. Executing command 'for i in {1..9}; do yes &> /dev/null & done'. Command exited with return code 0. ${stdout} = ${rc} = 0 ${rc} Logs the given message with the given level. 0 ${stdout} Logs the given message with the given level. Closes all open connections. ${rc} 0 Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Connect to the VNF via SSH and force VIM metric to increase. azure cluster_sa daily regression sa_02 sanity ${PROMETHEUS_POLL_RETRIES} msg=Metric polling retries is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_POLL_TIMEOUT} msg=Metric polling timeout is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_POLL_RETRIES} ${PROMETHEUS_POLL_TIMEOUT} Check VIM-based Metric Exceeds Threshold Runs the specified keyword and retries if it fails. Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad623fa30>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:56:00 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714067760.948,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. The metric 'osm_cpu_utilization' value is '0.175' which is lower than '60.0' Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad62450c0>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:57:00 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714067820.990,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. The metric 'osm_cpu_utilization' value is '0.175' which is lower than '60.0' Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f07f0>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:58:01 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714067881.033,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. The metric 'osm_cpu_utilization' value is '0.175' which is lower than '60.0' Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f1000>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 17:59:01 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714067941.069,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. The metric 'osm_cpu_utilization' value is '0.175' which is lower than '60.0' Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad61f3d00>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 18:00:01 GMT', 'Content-Length': '353'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714068001.106,"0.175"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 0.175 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. The metric 'osm_cpu_utilization' value is '0.175' which is lower than '60.0' Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad623da80>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 18:01:01 GMT', 'Content-Length': '357'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714068061.146,"99.94999999999999"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 99.94999999999999 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. Wait until the VIM metric exceeds threshold, which should lead to a scale up. azure cluster_sa daily regression sa_02 sanity ${threshold_time_sleep} ${THRESHOLD_TIME} + 1 Evaluates the given expression in Python and returns the result. ${threshold_time_sleep} = 2.0 ${threshold_time_sleep} minutes Wait scale-out threshold time plus 1 minute Pauses the test executed for the given time. Slept 2 minutes Wait scale-out threshold time plus 1 minute Wait until the VIM metric has exceeded threshold for the defined period in the descriptor. azure cluster_sa daily regression sa_02 sanity Auxiliar keyword to check if metric exceeds threshold ${PROMETHEUS_HOST} msg=Prometheus address is not available Fails unless the given variable exists within the current scope. ${PROMETHEUS_PORT} msg=Prometheus port is not available Fails unless the given variable exists within the current scope. ${METRIC_NAME} msg=Prometheus metric name is not available Fails unless the given variable exists within the current scope. ${metric_filter} ns_id=${NS_ID} Returns the given values which can then be assigned to a variables. ${metric_filter} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${metric_value} ${PROMETHEUS_HOST} ${PROMETHEUS_PORT} ${PROMETHEUS_USER} ${PROMETHEUS_PASSWORD} ${METRIC_NAME} ${metric_filter} Get the instant value of a metric from Prometheus using multiple filter parameters. The filter parameters are given to this function in key=value format (one argument per key/value pair). Fails if the metric is not found or has multiple values. Examples of execution: ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${metric}= Get Metric ${prometheus_ip} ${prometheus_port} "" ${metric} ${param1}=${value1} ${param2}=${value2} ${filter} ${EMPTY} Returns the given values which can then be assigned to a variables. ${filter} = ${param} @{filter_parameters} ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match} ${param_name} ${param_value} ${param} (.+)=(.+) msg=Syntax error in filter parameters Fails if ``string`` does not match ``pattern`` as a regular expression. ${match} = ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${param_name} = ns_id ${param_value} = 0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${match},${param_name},${param_value} Logs the given message with the given level. ns_id=0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875,ns_id,0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875 ${filter} SEPARATOR= ${filter} ${param_name}="${param_value}", Catenates the given items together and returns the resulted string. ${filter} = ns_id="0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875", ${resp} ${prometheus_ip} ${prometheus_port} ${prometheus_user} ${prometheus_password} query=${metric}{${filter}} Execute a Prometheus Instant Query using HTTP API. Return an inline json with the result of the query. The requested URL is the next: http://${prometheus_ip}:${prometheus_port}/api/v1/query?${querystring} ${auth} ${prometheus_user} ${prometheus_password} Returns a list containing given items. ${auth} = ['""', '""'] ${auth} None Returns the given values which can then be assigned to a variables. prometheus http://${prometheus_ip}:${prometheus_port} timeout=${TIMEOUT} max_retries=${MAX_RETRIES} verify=false auth=${auth} Create Session: create a HTTP session to a server Creating Session using : alias=prometheus, url=http://172.21.248.101:9091, headers={}, cookies={}, auth=<requests.auth.HTTPBasicAuth object at 0x7f9ad623f250>, timeout=30, proxies=None, verify=False, debug=0 ${resp} prometheus /api/v1/query?${querystring} timeout=${TIMEOUT} Sends a GET request on a previously created HTTP Session. GET Request : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D path_url=/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D headers={'User-Agent': 'python-requests/2.31.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Basic IiI6IiI='} body=None GET Response : url=http://172.21.248.101:9091/api/v1/query?query=osm_cpu_utilization%7Bns_id=%220fb6d0bf-9aff-47ca-b4ef-0717c3ff8875%22,%7D status=200, reason=OK headers={'Content-Encoding': 'gzip', 'Content-Type': 'application/json', 'Date': 'Thu, 25 Apr 2024 18:03:01 GMT', 'Content-Length': '357'} body={"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"osm_cpu_utilization","job":"airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291","metric_id":"vnf_cpu_util","ns_id":"0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875","project_id":"cf1c7659-f6bf-4d99-a183-e601f7c51259","vdu_id":"hackfest_basic_metrics-VM","vdu_name":"sa_02-vnf-hackfest_basic_metrics-VM-0","vim_id":"383e6ef5-984f-4df2-9cff-009261fbc291","vm_id":"8f63e2ab-1610-4a2d-a9a0-36d728cdb91b","vnf_member_index":"vnf"},"value":[1714068181.186,"99.94999999999999"]}]}} ${resp} = <Response [200]> 200 ${resp} Fails if response status code is different than the expected. ${resp.json()} ${resp} = {'status': 'success', 'data': {'resultType': 'vector', 'result': [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf... ${result_list} ${resp["data"]["result"]} Converts the given ``item`` to a Python ``list`` type. ${result_list} = [{'metric': {'__name__': 'osm_cpu_utilization', 'job': 'airflow_osm_vm_metrics_383e6ef5-984f-4df2-9cff-009261fbc291', 'metric_id': 'vnf_cpu_util', 'ns_id': '0fb6d0bf-9aff-47ca-b4ef-0717c3ff8875', 'pro... ${results} ${result_list} Returns and logs the length of the given item as an integer. Length is 1 ${results} = 1 0 ${results} msg=Metric ${metric} not found values=false Fails if objects are equal after converting them to real numbers. Argument types are: <class 'str'> <class 'int'> 1 ${results} msg=Metric ${metric} with multiple values values=false Fails if objects are unequal after converting them to integers. Argument types are: <class 'str'> <class 'int'> ${result_list[0]["value"][1]} ${metric_value} = 99.94999999999999 msg=The metric '${METRIC_NAME}' value is '${metric_value}' which is lower than '${METRIC_THRESHOLD}' Fails the test with the given message and optionally alters its tags. Check that the VIM metric has exceeded the threshold. azure cluster_sa daily regression sa_02 sanity 2 minutes Wait for auto-scale to take place Pauses the test executed for the given time. Slept 2 minutes Wait for auto-scale to take place @{vdur_list} ${VNF_ID} Return a list with the names of the VDU records of a VNF instance. ${vnf_id} Verifies that the given item is not empty. Length is 36 ${rc} ${stdout} osm vnf-show ${vnf_id} --literal | yq -r .vdur[].name Runs the given command in the system and returns the RC and output. Running command 'osm vnf-show 09e67741-cefa-44ca-94bb-8f5a44ec300a --literal | yq -r .vdur[].name 2>&1'. ${rc} = 0 ${stdout} = sa_02-vnf-hackfest_basic_metrics-VM-0 sa_02-vnf-hackfest_basic_metrics-VM-1 ${rc} ${SUCCESS_RETURN_CODE} msg=${stdout} values=False Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> @{vdur} ${stdout} Splits the ``string`` using ``separator`` as a delimiter string. @{vdur} = [ sa_02-vnf-hackfest_basic_metrics-VM-0 | sa_02-vnf-hackfest_basic_metrics-VM-1 ] @{vdur} @{vdur_list} = [ sa_02-vnf-hackfest_basic_metrics-VM-0 | sa_02-vnf-hackfest_basic_metrics-VM-1 ] ${vdur_list} Logs the length and contents of the ``list`` using given ``level``. List length is 2 and it contains following items: 0: sa_02-vnf-hackfest_basic_metrics-VM-0 1: sa_02-vnf-hackfest_basic_metrics-VM-1 ${vdurs} ${vdur_list} Returns and logs the length of the given item as an integer. Length is 2 ${vdurs} = 2 msg=There is no new VDU after auto-scaling Fails the test with the given message and optionally alters its tags. Check that the VNF has scaled up and the humber of VDUs has increased. azure cluster_sa daily regression sa_02 sanity ${NS_NAME} Delete a NS instance. ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} result_format=number Converts between supported `time formats`. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} ${ns_delete_max_wait_time} * ${VIM_TIMEOUT_MULTIPLIER} Evaluates the given expression in Python and returns the result. ${ns_delete_max_wait_time} = 240.0 ${ns_delete_max_wait_time} Logs the given message with the given level. 240.0 ${rc} ${stdout} osm ns-delete ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-delete sa_02 2>&1'. ${rc} = 0 ${stdout} = Deletion in progress ${stdout} Logs the given message with the given level. Deletion in progress ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${ns_delete_max_wait_time} ${NS_DELETE_POL_TIME} Check For NS Instance To Be Deleted ${ns} Runs the specified keyword and retries if it fails. ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ | 5964e3c5-f810-4b76-bc07-05ac834ebc8b | sa_02-vnf-hackfest_basic_metrics-VM-1 | ACTIVE | osm-ext=172.21.248.191 | ubuntu20.04 | simple_requires-1-1-flv | | 8f63e2ab-1610-4a2d-a9a0-36d728cdb91b | sa_02-vnf-hackfest_basic_metrics-VM-0 | ACTIVE | osm-ext=172.21.249.34 | ubuntu20.04 | simple_requires-1-1-flv | | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+---------------------------------------+--------+------------------------+-------------+-------------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep sa_02 2>&1'. ${rc} = 0 ${stdout} = sa_02 ${rc},${stdout} Logs the given message with the given level. 0,sa_02 ${stdout} ${ns} Fails if objects are equal after converting them to strings. sa_02 == sa_02 ${ns} Check if a given NS instance is not present in OSM. ${rc} ${stdout} openstack server list Runs the given command in the system and returns the RC and output. Running command 'openstack server list 2>&1'. ${rc} = 0 ${stdout} = +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name ... ${rc},${stdout} Logs the given message with the given level. 0,+--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ | ef1bbf08-4419-4b2b-868b-56c9015708cc | osm-master-12468 | ACTIVE | osm-ext=172.21.248.101 | ubuntu22.04 | osm.sanity | | d1c13b29-6684-4bd4-b0dd-e37f812251b6 | tfs-controller | ACTIVE | osm-ext=172.21.249.222 | ubuntu22.04 | 8CPU16RAM120DISK | | 50ff3fab-0638-4c0c-90f0-482fda44502d | connectivity-checker | ACTIVE | osm-ext=172.21.248.52 | ubuntu22.04 | m1.small | | efef733e-fa09-4a84-9166-be07e67991ee | osm-cicd-4 | ACTIVE | osm-ext=172.21.249.4 | ubuntu22.04 | cicd.stage-3 | | cdb8074d-4819-48c2-a653-48f58644103f | osm-cicd-3 | ACTIVE | osm-ext=172.21.249.3 | ubuntu22.04 | 16CPU32RAM200DISK | | c577acd0-532d-40b1-a55f-df851a7c10b5 | osm-cicd-2 | ACTIVE | osm-ext=172.21.249.2 | ubuntu22.04 | 16CPU32RAM200DISK | | d60af501-35ea-4cad-a30f-a4b163ee1647 | osm-cicd-1 | ACTIVE | osm-ext=172.21.249.1 | ubuntu22.04 | cicd.stage-1 | | e7335e3f-07d7-4f3d-9696-f74456db12ef | grafana | ACTIVE | osm-ext=172.21.249.69 | ubuntu20.04 | srsLTE-vdu-flv-7 | | 0ad5ca31-1201-46ba-b146-cd855ed154a8 | prometheus | ACTIVE | osm-ext=172.21.248.212 | ubuntu20.04 | srsLTE-vdu-flv-7 | | edd53c21-a6c0-4719-a6ee-291adfb9c011 | inframon-juju-controller | ACTIVE | osm-ext=172.21.249.111 | ubuntu20.04 | vThunder_vnfd-VM-flv | | 2244faf7-d023-40c2-b255-70c68eee9cc5 | inframon-tools | ACTIVE | osm-ext=172.21.248.15 | ubuntu22.04 | m1.small | +--------------------------------------+--------------------------+--------+------------------------+-------------+----------------------+ ${rc} ${stdout} osm ns-list | awk '{print $2}' | grep ${ns} Runs the given command in the system and returns the RC and output. Running command 'osm ns-list | awk '{print $2}' | grep sa_02 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${ns} Fails if objects are equal after converting them to strings. Delete NS instance. azure cleanup cluster_sa daily regression sa_02 sanity ${NSD_NAME} Delete a NS package from OSM. ${rc} ${stdout} Run And Return Rc And Output osm nspkg-delete ${nsd_id} Runs the keyword and continues execution even if a failure occurs. osm nspkg-delete ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-delete hackfest_basic-ns-metrics 2>&1'. ${rc} = 0 ${stdout} = Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${stdout} Logs the given message with the given level. Deleted ${NSD_DELETE_MAX_WAIT_TIME} ${NSD_DELETE_POL_TIME} Check For NSD ${nsd_id} Runs the specified keyword and retries if it fails. ${nsd_id} Check that a NS package exists in OSM. ${rc} ${stdout} osm nspkg-list | awk '{print $2}' | grep ${nsd_id} Runs the given command in the system and returns the RC and output. Running command 'osm nspkg-list | awk '{print $2}' | grep hackfest_basic-ns-metrics 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${nsd_id} Fails if objects are equal after converting them to strings. Delete NS package from OSM. azure cleanup cluster_sa daily regression sa_02 sanity ${VNFD_NAME} Delete a VNF package from OSM. ${rc} ${stdout} osm vnfpkg-delete ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-delete hackfest_basic_metrics-vnf 2>&1'. ${rc} = 0 ${stdout} = Deleted ${stdout} Logs the given message with the given level. Deleted ${rc} ${SUCCESS_RETURN_CODE} Fails if objects are unequal after converting them to integers. Argument types are: <class 'int'> <class 'str'> ${VNFD_DELETE_MAX_WAIT_TIME} ${VNFD_DELETE_POL_TIME} Check For VNFD ${vnfd_id} Runs the specified keyword and retries if it fails. ${vnfd_id} Check that a VNF package exists in OSM. ${rc} ${stdout} osm vnfpkg-list | awk '{print $2}' | grep ${vnfd_id} Runs the given command in the system and returns the RC and output. Running command 'osm vnfpkg-list | awk '{print $2}' | grep hackfest_basic_metrics-vnf 2>&1'. ${rc} = 1 ${stdout} = ${rc},${stdout} Logs the given message with the given level. 1, ${stdout} ${vnfd_id} Fails if objects are unequal after converting them to strings. ${stdout} ${vnfd_id} Fails if objects are equal after converting them to strings. Delete VNF package from OSM. azure cleanup cluster_sa daily regression sa_02 sanity Suite Cleanup Runs the given keyword with the given arguments and ignores possible error. Test Suite Cleanup: Deleting descriptors and NS instance Delete NS ${NS_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete NSD ${NSD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. Delete VNFD ${VNFD_NAME} Runs the given keyword with the given arguments, if one or more tests failed. [SA-02] VNF with VIM-based metrics and auto-scaling. All Tests cluster_k8s cluster_main cluster_sa Testsuite Testsuite.Hackfest Basic Testsuite.Hackfest Cloudinit Testsuite.K8S 04-Openldap Helm Testsuite.Sa 02-Vnf With Vim Metrics And Autoscaling