blob: 253665cddf3aaf3973fac4c7e964ed1e01044914 [file] [log] [blame]
garciadeblas7a9e0312023-12-11 22:24:46 +01001*** Comments ***
garciadeblas499c8672021-03-25 11:51:08 +01002# 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
garciadeblas7a9e0312023-12-11 22:24:46 +010014
garciadeblas499c8672021-03-25 11:51:08 +010015*** Settings ***
garciadeblasf4ebaa82022-06-23 13:33:26 +020016Documentation [BASIC-17] Delete VNF Package Before NS Package.
garciadeblas4cf45d72021-04-08 13:52:22 +020017
garciadeblas499c8672021-03-25 11:51:08 +010018Library OperatingSystem
19Library String
20Library Collections
21Library Process
22Library SSHLibrary
23
garciadeblas7a9e0312023-12-11 22:24:46 +010024Resource ../lib/vnfd_lib.resource
25Resource ../lib/nsd_lib.resource
garciadeblas499c8672021-03-25 11:51:08 +010026
garciadeblas7a9e0312023-12-11 22:24:46 +010027Test Tags basic_17 cluster_main daily regression azure
garciadeblas4cf45d72021-04-08 13:52:22 +020028
garciadeblas499c8672021-03-25 11:51:08 +010029Suite Teardown Run Keyword And Ignore Error Suite Cleanup
30
31
almagiab4697d32021-05-25 08:56:17 +020032*** Variables ***
33# NS and VNF descriptor package folder and ids
garciadeblas7a9e0312023-12-11 22:24:46 +010034${VNFD_PKG} hackfest_basic_vnf
35${VNFD_NAME} hackfest_basic-vnf
36${NSD_PKG} hackfest_basic_ns
37${NSD_NAME} hackfest_basic-ns
almagiab4697d32021-05-25 08:56:17 +020038
39
garciadeblas499c8672021-03-25 11:51:08 +010040*** Test Cases ***
41Create VNF Package
garciadeblas7a9e0312023-12-11 22:24:46 +010042 [Documentation] Upload VNF package for the testsuite.
43 Create VNFD '%{PACKAGES_FOLDER}/${VNFD_PKG}'
garciadeblas499c8672021-03-25 11:51:08 +010044
45Create NS Package
garciadeblas7a9e0312023-12-11 22:24:46 +010046 [Documentation] Upload NS package for the testsuite.
47 Create NSD '%{PACKAGES_FOLDER}/${NSD_PKG}'
garciadeblas499c8672021-03-25 11:51:08 +010048
49Cannot Delete VNF Package
garciadeblas7a9e0312023-12-11 22:24:46 +010050 [Documentation] Assert that the VNF package cannot be deleted without deleting the corresponding NS package using it.
51 Assert Failure Delete VNFD ${VNFD_NAME}
garciadeblas499c8672021-03-25 11:51:08 +010052
53Delete NS Package
garciadeblas7a9e0312023-12-11 22:24:46 +010054 [Documentation] Delete NS package from OSM.
garciadeblas4cf45d72021-04-08 13:52:22 +020055 [Tags] cleanup
garciadeblas7a9e0312023-12-11 22:24:46 +010056 Delete NSD ${NSD_NAME}
garciadeblas499c8672021-03-25 11:51:08 +010057
58Delete VNF Package
garciadeblas7a9e0312023-12-11 22:24:46 +010059 [Documentation] Delete VNF package from OSM.
garciadeblas4cf45d72021-04-08 13:52:22 +020060 [Tags] cleanup
garciadeblas7a9e0312023-12-11 22:24:46 +010061 Delete VNFD ${VNFD_NAME}
garciadeblas499c8672021-03-25 11:51:08 +010062
63
64*** Keywords ***
65Suite Cleanup
garciadeblasf4ebaa82022-06-23 13:33:26 +020066 [Documentation] Test Suit Cleanup: Deleting NS and VNF packages
garciadeblas7a9e0312023-12-11 22:24:46 +010067 Run Keyword If Any Tests Failed Delete NSD ${NSD_NAME}
68 Run Keyword If Any Tests Failed Delete VNFD ${VNFD_NAME}