Bug 2327 fix to verify ipaddress in sol003_02 testsuite
[osm/tests.git] / robot-systest / README.md
1 <!--
2  Licensed under the Apache License, Version 2.0 (the "License");
3  you may not use this file except in compliance with the License.
4  You may obtain a copy of the License at
5
6     http://www.apache.org/licenses/LICENSE-2.0
7
8  Unless required by applicable law or agreed to in writing, software
9  distributed under the License is distributed on an "AS IS" BASIS,
10  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11  See the License for the specific language governing permissions and
12  limitations under the License.
13 -->
14
15 # Robot Framework: Test usage
16
17 ## Requirements
18
19 - OSM client installed (<https://osm.etsi.org/docs/user-guide/03-installing-osm.html#installing-standalone-osm-client>)
20 - devops repository cloned in home (<https://osm.etsi.org/gerrit/#/admin/projects/osm/devops>)
21 - The descriptor packages used on each test are expected to be in `${PACKAGES_FOLDER}`.
22 - A set of environment variables (there is an example file located at devops/robot-systest/environment.rc):
23   - `OSM_HOSTNAME`: IP address of target OSM.
24   - `OS_CLOUD`: Cloud credentialss.
25   - `VIM_TARGET`: VIM where tests will be run.
26   - `VIM_MGMT_NET`: VIM management network, reachable from robot.
27   - `PACKAGES_FOLDER`: Path where descriptor packages repository are cloned: https://osm.etsi.org/gitlab/vnf-onboarding/osm-packages/
28   - `ROBOT_DEVOPS_FOLDER`: Where the devops repository is located.
29   - `ROBOT_REPORT_FOLDER`: Where robot outpul will be placed.
30
31 ## Installation
32
33 ```bash
34 sudo -H python3 -m pip install --ignore-installed haikunator requests pyvcloud progressbar pathlib robotframework robotframework-seleniumlibrary robotframework-requests robotframework-SSHLibrary
35 sudo snap install yq
36 sudo apt-get install -y python3-openstackclient  # Installs Queens by default
37 ```
38
39 ## Usage
40
41 Example using hackfest basic test.
42
43 ```bash
44
45 # Set your environment variables in environment.rc as specified in requirements
46 source environment.rc
47
48 cd ~/devops/robot-systest
49 robot -d ${ROBOT_REPORT_FOLDER} testsuite/hackfest_basic.robot
50 ```