aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/robot
diff options
context:
space:
mode:
Diffstat (limited to 'resources/libraries/robot')
-rw-r--r--resources/libraries/robot/crypto/ipsec.robot47
-rw-r--r--resources/libraries/robot/shared/default.robot30
2 files changed, 71 insertions, 6 deletions
diff --git a/resources/libraries/robot/crypto/ipsec.robot b/resources/libraries/robot/crypto/ipsec.robot
index 74a1a53f25..80d2937e37 100644
--- a/resources/libraries/robot/crypto/ipsec.robot
+++ b/resources/libraries/robot/crypto/ipsec.robot
@@ -254,21 +254,21 @@
| Set up IPv4 IPSec functional test
| | [Documentation]
-| | ... | Set up IPv4 IPSec functional test
+| | ... | Set up IPv4 IPSec functional test.
| | ...
| | Set up functional test
| | Configure topology for IPv4 IPsec testing
| Set up IPv6 IPSec functional test
| | [Documentation]
-| | ... | Set up IPv6 IPSec functional test
+| | ... | Set up IPv6 IPSec functional test.
| | ...
| | Set up functional test
| | Configure topology for IPv6 IPsec testing
| Tear down IPSec functional test
| | [Documentation]
-| | ... | Tear down IPSec functional test
+| | ... | Tear down IPSec functional test.
| | ...
| | ... | *Example:*
| | ...
@@ -278,3 +278,44 @@
| | ...
| | VPP IPsec Show | ${dut_node}
| | Tear down functional test
+
+| Set up IPSec SW device functional test
+| | [Documentation]
+| | ... | Set up IPSec SW device functional test for required IP version.
+| | ...
+| | ... | *Arguments:*
+| | ... | - ${ip_version} - IP version: IPv4 or IPv6. Type: string
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Set up IPSec SW device functional test \| IPv4 \|
+| | ...
+| | [Arguments] | ${ip_version}
+| | ...
+| | ${duts}= | Get Matches | ${nodes} | DUT*
+| | :FOR | ${dut} | IN | @{duts}
+| | | Import Library | resources.libraries.python.VppConfigGenerator
+| | | ... | WITH NAME | ${dut}
+| | | Run keyword | ${dut}.Set Node | ${nodes['${dut}']}
+| | | Run keyword | ${dut}.Set Vpp Startup Conf Backup
+| | | Run keyword | ${dut}.Set Vpp Logfile | /tmp/vpp.log
+| | | Run keyword | ${dut}.Add Unix Nodaemon
+| | | Run keyword | ${dut}.Add Unix Log
+| | | Run keyword | ${dut}.Add Unix Coredump
+| | | Run keyword | ${dut}.Add Unix CLI Listen | /run/vpp/cli.sock
+| | | Run keyword | ${dut}.Add Unix Gid
+| | | Run keyword | ${dut}.Add Api Segment Gid
+| | | Run keyword | ${dut}.Add DPDK SW Cryptodev | ${1}
+| | Apply startup configuration on all VPP DUTs | restart_vpp=${FALSE}
+| | Set up functional test
+| | Run Keyword | Configure topology for ${ip_version} IPsec testing
+
+| Tear down IPSec SW device functional test
+| | [Documentation]
+| | ... | Tear down IPSec SW device functional test.
+| | ...
+| | ${duts}= | Get Matches | ${nodes} | DUT*
+| | :FOR | ${dut} | IN | @{duts}
+| | | VPP IPsec Show | ${nodes['${dut}']}
+| | | Run keyword | ${dut}.Restore Config
+| | Tear down functional test
diff --git a/resources/libraries/robot/shared/default.robot b/resources/libraries/robot/shared/default.robot
index 6c80f9827d..74ad8d3f09 100644
--- a/resources/libraries/robot/shared/default.robot
+++ b/resources/libraries/robot/shared/default.robot
@@ -24,7 +24,6 @@
| Library | resources.libraries.python.TGSetup
| Library | resources.libraries.python.L2Util
| Library | resources.libraries.python.Tap
-| Library | resources.libraries.python.VppConfigGenerator
| Library | resources.libraries.python.VppCounters
| Library | resources.libraries.python.VPPUtil
| Library | resources.libraries.python.Trace
@@ -265,13 +264,38 @@
| | :FOR | ${dut} | IN | @{duts}
| | | Run keyword | ${dut}.Add DPDK Cryptodev | ${count}
+| Add crypto SW device on all DUTs
+| | [Documentation] | Add required number of crypto SW devices to VPP startup
+| | ... | configuration on all DUTs.
+| | ...
+| | ... | *Arguments:*
+| | ... | - ${count} - Number of SW crypto devices. Type: integer
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Add SW cryptodev on all DUTs \| ${4} \|
+| | ...
+| | [Arguments] | ${count}
+| | ${duts}= | Get Matches | ${nodes} | DUT*
+| | :FOR | ${dut} | IN | @{duts}
+| | | Run keyword | ${dut}.Add DPDK SW Cryptodev | ${count}
+
| Apply startup configuration on all VPP DUTs
| | [Documentation] | Write startup configuration and restart VPP on all DUTs.
| | ...
+| | ... | *Arguments:*
+| | ... | - ${restart_vpp} - Whether to restart VPP (Optional). Type: boolean
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Apply startup configuration on all VPP DUTs \| ${False} \|
+| | ...
+| | [Arguments] | ${restart_vpp}=${True}
+| | ...
| | ${duts}= | Get Matches | ${nodes} | DUT*
| | :FOR | ${dut} | IN | @{duts}
-| | | Run keyword | ${dut}.Apply Config
-| | Update All Interface Data On All Nodes | ${nodes} | skip_tg=${TRUE}
+| | | Run keyword | ${dut}.Apply Config | restart_vpp=${restart_vpp}
+| | Update All Interface Data On All Nodes | ${nodes} | skip_tg=${True}
| Save VPP PIDs
| | [Documentation] | Get PIDs of VPP processes from all DUTs in topology and\