From: ramonsalguer Date: Fri, 17 Jul 2020 18:08:52 +0000 (+0000) Subject: Allows overriding EPA attributes to force package compatibility with specific VIMs X-Git-Tag: release-v9.0-start~39 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=89edc0745c3e458889449945c38f694821ceebdb;p=osm%2Ftests.git Allows overriding EPA attributes to force package compatibility with specific VIMs Change-Id: I07056603053fe96e6ac453314e128d5a7abbbebc Signed-off-by: ramonsalguer --- diff --git a/robot-systest/lib/vnfd_lib.robot b/robot-systest/lib/vnfd_lib.robot index fdef1ac..5785172 100644 --- a/robot-systest/lib/vnfd_lib.robot +++ b/robot-systest/lib/vnfd_lib.robot @@ -41,9 +41,27 @@ Get VNFDs List Create VNFD - [Arguments] ${vnfd_pkg} - - ${rc} ${stdout}= Run and Return RC and Output osm vnfd-create ${vnfd_pkg} + [Documentation] 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. + + [Arguments] ${vnfd_pkg} ${overrides}=${EMPTY} + + # If env variable "OVERRIDES" exists, it prevails over the value in the argument + ${overrides}= Get Environment Variable OVERRIDES default=${overrides} + + # Proceedes with the onboarding with the appropriate arguments + ${rc} ${stdout}= Run and Return RC and Output osm vnfd-create ${overrides} ${vnfd_pkg} log ${stdout} Should Be Equal As Integers ${rc} ${success_return_code} ${lines}= Get Line Count ${stdout}