+# -*- coding: utf-8 -*-\r
+\r
+##\r
+# Copyright 2019 TATA ELXSI\r
+#\r
+# All Rights Reserved.\r
+#\r
+# Licensed under the Apache License, Version 2.0 (the "License"); you may\r
+# not use this file except in compliance with the License. You may obtain\r
+# a copy of the License at\r
+#\r
+# http://www.apache.org/licenses/LICENSE-2.0\r
+#\r
+# Unless required by applicable law or agreed to in writing, software\r
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT\r
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the\r
+# License for the specific language governing permissions and limitations\r
+# under the License.\r
+##\r
+\r
+## Author: Ragavi D (ragavi.d@tataelxsi.co.in)\r
+\r
+*** Settings ***\r
+Documentation Test Suite to create hackfest basic nestwork service\r
+Suite Teardown Run Keyword And Ignore Error Test Cleanup\r
+Library OperatingSystem\r
+Library String\r
+Library Collections\r
+Resource ../../lib/cli/vnfd_lib.robot\r
+Resource ../../lib/cli/nsd_lib.robot\r
+Resource ../../lib/cli/ns_lib.robot\r
+Resource ../../lib/cli/vim_account_lib.robot\r
+Library ../../lib/custom_lib.py\r
+Variables ../../resource/cli/ubuntu-cloudinit_ns_data.py\r
+\r
+*** Variables ***\r
+@{vnfd_ids}\r
+${nsd_id} ${EMPTY}\r
+@{nsd_ids}\r
+@{ns_ids}\r
+${ns_config} '{vld: [ {name: mgmtnet, vim-network-name: osm-ext} ], additionalParamsForVnf: [ { member-vnf-index: "1", additionalParams: { password: "PASSWORD" } } ] }'\r
+\r
+*** Test Cases ***\r
+Create Ubuntu CloudInit VNF Descriptor\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ Build VNF Descriptor ${vnfdPckgPath}\r
+ ${vnfd_id}= Create VNFD '${CURDIR}${/}../../..${vnfdPckgPath}${vnfdPckg}'\r
+ Append To List ${vnfd_ids} ${vnfd_id}\r
+\r
+Create Ubuntu CloudInit NS Descriptor\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ Build NS Descriptor ${nsdPckgPath}\r
+ ${nsd_id}= Create NSD '${CURDIR}${/}../../..${nsdPckgPath}${nsdPckg}'\r
+ Append To List ${nsd_ids} ${nsd_id}\r
+\r
+Network Service Instance Test\r
+ [Documentation] Launch and terminate network services\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ : FOR ${vim_name} IN @{vim}\r
+ \ Launch Network Services and Return ${vim_name} ${ns_config}\r
+\r
+Delete NS Instance Test\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ : FOR ${ns} IN @{ns_ids}\r
+ \ Delete NS ${ns}\r
+\r
+Delete NS Descriptor Test\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ : FOR ${nsd} IN @{nsd_ids}\r
+ \ Delete NSD ${nsd}\r
+\r
+Delete VNF Descriptor Test\r
+ [Tags] comprehensive ubuntu-cloudinit_ns\r
+ : FOR ${vnfd_id} IN @{vnfd_ids}\r
+ \ Delete VNFD ${vnfd_id}\r
+\r
+*** Keywords ***\r
+Test Cleanup\r
+ [Documentation] Test Suit Cleanup: Deliting Descriptor, instance and vim\r
+ : FOR ${ns} IN @{ns_ids}\r
+ \ Delete NS ${ns}\r
+ : FOR ${nsd} IN @{nsd_ids}\r
+ \ Delete NSD ${nsd}\r
+ : FOR ${vnfd} IN @{vnfd_ids}\r
+ \ Delete VNFD ${vnfd}\r
+ # :FOR ${vim_id} IN @{vim}\r
+ # Delete Vim Account ${vim_id}\r