1 # Copyright (c) 2020 Cisco and/or its affiliates.
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:
6 # http://www.apache.org/licenses/LICENSE-2.0
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.
14 """Keywords used in suite teardowns."""
17 | Library | resources.libraries.python.DPDK.DPDKTools
18 | Library | resources.libraries.python.TrafficGenerator
19 | Library | resources.libraries.python.DUTSetup
21 | Documentation | Suite teardown keywords.
26 | | ... | Common suite teardown for tests.
28 | | ... | *Arguments:*
29 | | ... | - ${actions} - Additional teardown action. Type: list
31 | | [Arguments] | @{actions}
33 | | FOR | ${action} | IN | @{actions}
34 | | | Run Keyword | Additional Suite Tear Down Action For ${action}
36 | | Remove All Added VIF Ports On All DUTs From Topology | ${nodes}
38 | Additional Suite Tear Down Action For performance
40 | | ... | Additional teardown for suites which uses performance measurement.
42 | | Run Keyword And Ignore Error | Teardown traffic generator | ${tg}
44 | Additional Suite Tear Down Action For dpdk
46 | | ... | Additional teardown for suites which uses dpdk.
48 | | FOR | ${dut} | IN | @{duts}
49 | | | Cleanup DPDK Framework
50 | | | ... | ${nodes['${dut}']} | ${${dut}_${int}1}[0] | ${${dut}_${int}2}[0]
53 | Additional Suite Tear Down Action For hoststack
55 | | ... | Additional teardown for suites which uses hoststack test programs.
56 | | ... | Ensure all hoststack test programs are no longer running on all DUTS.
58 | | FOR | ${dut} | IN | @{duts}
59 | | | Kill Program | ${nodes['${dut}']} | iperf3
60 | | | Kill Program | ${nodes['${dut}']} | vpp_echo