X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Flibraries%2Frobot%2Fshared%2Fdefault.robot;h=853f567cf691fb7c334c436f42eec4bcdedd2bfd;hp=c9d924edc1677ce5651f04941268fb630f71b38c;hb=refs%2Fchanges%2F67%2F30567%2F11;hpb=636c8c711b5f44cd0ef7c4a04a4b3bc0aad6566d diff --git a/resources/libraries/robot/shared/default.robot b/resources/libraries/robot/shared/default.robot index c9d924edc1..853f567cf6 100644 --- a/resources/libraries/robot/shared/default.robot +++ b/resources/libraries/robot/shared/default.robot @@ -1,4 +1,4 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2021 Cisco and/or its affiliates. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at: @@ -20,10 +20,10 @@ | Library | OperatingSystem | Library | String | +| Library | resources.libraries.python.Adl | Library | resources.libraries.python.Classify | Library | resources.libraries.python.CpuUtils | Library | resources.libraries.python.CoreDumpUtil -| Library | resources.libraries.python.Cop | Library | resources.libraries.python.DUTSetup | Library | resources.libraries.python.L2Util | Library | resources.libraries.python.InterfaceUtil @@ -34,17 +34,18 @@ | Library | resources.libraries.python.PapiHistory | Library | resources.libraries.python.SchedUtils | Library | resources.libraries.python.Tap +| Library | resources.libraries.python.Tap.TapFeatureMask | Library | resources.libraries.python.TestConfig | Library | resources.libraries.python.TGSetup | Library | resources.libraries.python.topology.Topology | Library | resources.libraries.python.Trace +| Library | resources.libraries.python.VhostUser.VirtioFeatureMask | Library | resources.libraries.python.VppCounters | Library | resources.libraries.python.VPPUtil | | Resource | resources/libraries/robot/lb/load_balancer.robot | Resource | resources/libraries/robot/crypto/ipsec.robot | Resource | resources/libraries/robot/features/acl.robot -| Resource | resources/libraries/robot/features/gbp.robot | Resource | resources/libraries/robot/features/policer.robot | Resource | resources/libraries/robot/ip/ip4.robot | Resource | resources/libraries/robot/ip/ip6.robot @@ -58,7 +59,6 @@ | Resource | resources/libraries/robot/overlay/lisp.robot | Resource | resources/libraries/robot/overlay/lispgpe.robot | Resource | resources/libraries/robot/overlay/lisp_api.robot -| Resource | resources/libraries/robot/performance/performance_limits.robot | Resource | resources/libraries/robot/performance/performance_utils.robot | Resource | resources/libraries/robot/shared/interfaces.robot | Resource | resources/libraries/robot/shared/container.robot @@ -74,6 +74,26 @@ | ${cpu_alloc_str}= | ${0} *** Keywords *** +# TODO: Sort keywords alphabetically. + +| Call Resetter +| | [Documentation] +| | ... | Check for a presence of test variable \${resetter}. +| | ... | If it exists (and not None), call the resetter (as a Python callable). +| | ... | This is usually used to reset any state on DUT before next trial. +| | +| | ... | TODO: Move to a more specific library if needed. +| | +| | ... | *Example:* +| | +| | ... | \| Call Resetter \| +| | +| | ${resetter} = | Get Resetter +| | # See http://robotframework.org/robotframework/3.1.2/libraries/BuiltIn.html +| | # #Evaluating%20expressions for $variable (without braces) syntax. +| | # Parens are there to perform the call. +| | Run Keyword If | $resetter | Evaluate | $resetter() + | Configure crypto device on all DUTs | | [Documentation] | Verify if Crypto QAT device virtual functions are | | ... | initialized on all DUTs. If parameter force_init is set to True, then @@ -151,7 +171,7 @@ | | | Run Keyword | ${dut}.Add Unix Nodaemon | | | Run Keyword | ${dut}.Add Unix Coredump | | | Run Keyword | ${dut}.Add Socksvr | ${SOCKSVR_PATH} -| | | Run Keyword | ${dut}.Add Main Heap Size | 2G +| | | Run Keyword | ${dut}.Add Main Heap Size | ${${heap_size_mult}*${2}}G | | | Run Keyword | ${dut}.Add Main Heap Page Size | 2M | | | Run Keyword | ${dut}.Add Statseg Size | 2G | | | Run Keyword | ${dut}.Add Statseg Page Size | 2M @@ -205,9 +225,10 @@ | | | ${thr_count_int}= | Run Keyword If | ${smt_used} | | | ... | Evaluate | int(${cpu_count_int}*2) | | | ... | ELSE | Set variable | ${thr_count_int} +| | | ${rxq_ratio} = | Get Variable Value | \${rxq_ratio} | ${2} | | | ${rxq_count_int}= | Run Keyword If | ${rx_queues} | | | ... | Set variable | ${rx_queues} -| | | ... | ELSE | Evaluate | int(${thr_count_int}/2) +| | | ... | ELSE | Evaluate | int(${thr_count_int}/${rxq_ratio}) | | | ${rxq_count_int}= | Run Keyword If | ${rxq_count_int} == 0 | | | ... | Set variable | ${1} | | | ... | ELSE | Set variable | ${rxq_count_int}