From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 68679A050D; Wed, 13 Apr 2022 16:54:50 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3B6A040694; Wed, 13 Apr 2022 16:54:50 +0200 (CEST) Received: from mail-il1-f228.google.com (mail-il1-f228.google.com [209.85.166.228]) by mails.dpdk.org (Postfix) with ESMTP id B21AC4068E for ; Wed, 13 Apr 2022 16:54:48 +0200 (CEST) Received: by mail-il1-f228.google.com with SMTP id r11so1278371ila.1 for ; Wed, 13 Apr 2022 07:54:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iol.unh.edu; s=unh-iol; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=2SSdv1qOuPTA6IWfbOodzcM6flZ5Lid+Nzl+ATHpqR4=; b=iGQW/13UBEc7ABie0biI9lVv83rwW8VzcttaQRkTVexqi+QNU2AoIOZUPl379U//fG BAUhKKjEyvimQbUSYaTPrOoDGxWsQdcNsmifUZMJzHw0rqNjxAapM7hRJ/c/IA7bfu4b 6X2XWZ1FixBpa6DxwZBurlQ4i4i2JP8/5rLzw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2SSdv1qOuPTA6IWfbOodzcM6flZ5Lid+Nzl+ATHpqR4=; b=34maxMgu+m4vG1h+CzPBo08gvDgCuEAx5ewU1lbvdQjhqByoA3olV5GOc9z0Pj/S5z MH7OiQtFdeNeWW0ZyaFyuJ/hmbn82rwFWYN84hORUTomQXRgfLBH9QdSRTle23jAQJmv z2AyzemAJ/up2c21CvlDHA2240VuaAu5Y9wi8K090Ta09ANarN91pD9ebx3lQywuJKB9 00rFFW9+SNlXFKN7lIjJDPGqgbFVDOCjtNOwDtr8qBDCW0r6xoVYmvy/bxPIH5dXYGyi yp93BavpMK+xjhcvwaMiF1EsjtruEwsDNJi6g7Dp6R9sWqhfvVRO7RCfCLhQeO0lguEU JAHA== X-Gm-Message-State: AOAM532eiLbXB3K8wElY6pJnL6OZrOF/A5JoF3Wev+uBYGeLYw1cBwyL 3S4NYEjw87aSX/ccItx63UhIBhqtxhRdsFTkRu6mWQUR7h7BN2voI61g0jP2vDeW7dERcrEbGhk XOEjcOnW7T+XqBDW3CgmCyVpPejk721kjIJMSDm6i1RS9NSyu7SphHPa/G+HOpA2kWEB5FwusWY QM+0b2CrfCDNCRRA== X-Google-Smtp-Source: ABdhPJy09YHyUy3NvM+5Y2H7eh61TOxxKC9J9Mplc/5dfmoQpAb7MIBOrcJPF7+Wbt7QXvSjsSZMXsSmRogS X-Received: by 2002:a92:6e0b:0:b0:2c9:a276:58cc with SMTP id j11-20020a926e0b000000b002c9a27658ccmr18583957ilc.199.1649861687923; Wed, 13 Apr 2022 07:54:47 -0700 (PDT) Received: from postal.iol.unh.edu (postal.iol.unh.edu. [2606:4100:3880:1234::84]) by smtp-relay.gmail.com with ESMTPS id p6-20020a029186000000b003263a48f105sm265556jag.19.2022.04.13.07.54.47 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Apr 2022 07:54:47 -0700 (PDT) X-Relaying-Domain: iol.unh.edu Received: from iol.unh.edu (unknown [IPv6:2606:4100:3880:1257::105d]) by postal.iol.unh.edu (Postfix) with ESMTP id 3D149605183B; Wed, 13 Apr 2022 10:54:47 -0400 (EDT) From: ohilyard@iol.unh.edu To: dts@dpdk.org Cc: lijuan.tu@intel.com, juraj.linkes@pantheon.tech, Owen Hilyard Subject: [PATCH v3 3/3] all: ran formatter Date: Wed, 13 Apr 2022 10:54:37 -0400 Message-Id: <20220413145437.31526-3-ohilyard@iol.unh.edu> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220413145437.31526-1-ohilyard@iol.unh.edu> References: <20220413145437.31526-1-ohilyard@iol.unh.edu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org From: Owen Hilyard It looks like some other parts of DTS were not formatted properly. Since the formatter script is all or nothing, I have to push those up as well. Signed-off-by: Owen Hilyard --- framework/dut.py | 2 +- ...uite_cvl_advanced_iavf_rss_pppol2tpoudp.py | 447 +++++++++--------- tests/TestSuite_cvl_iavf_fdir_pppol2tpoudp.py | 90 ++-- tests/TestSuite_ddp_gtp.py | 2 +- tests/TestSuite_ddp_mpls.py | 2 +- tests/TestSuite_eeprom_dump.py | 10 +- ...te_ixgbe_vf_get_extra_queue_information.py | 2 +- tests/TestSuite_power_bidirection_channel.py | 2 +- tests/TestSuite_power_negative.py | 2 +- tests/TestSuite_rte_flow.py | 2 +- tests/TestSuite_runtime_vf_queue_number.py | 2 +- tests/TestSuite_shutdown_api.py | 2 +- tests/TestSuite_unit_tests_cmdline.py | 4 +- tests/TestSuite_unit_tests_crc.py | 4 +- tests/TestSuite_unit_tests_cryptodev_func.py | 4 +- tests/TestSuite_unit_tests_dump.py | 4 +- tests/TestSuite_unit_tests_eal.py | 4 +- tests/TestSuite_unit_tests_event_timer.py | 4 +- tests/TestSuite_unit_tests_kni.py | 4 +- tests/TestSuite_unit_tests_loopback.py | 4 +- tests/TestSuite_unit_tests_lpm.py | 4 +- tests/TestSuite_unit_tests_mbuf.py | 4 +- tests/TestSuite_unit_tests_mempool.py | 4 +- tests/TestSuite_unit_tests_pmd_perf.py | 4 +- tests/TestSuite_unit_tests_power.py | 4 +- tests/TestSuite_unit_tests_qos.py | 4 +- tests/TestSuite_unit_tests_ring.py | 4 +- tests/TestSuite_unit_tests_ringpmd.py | 4 +- tests/TestSuite_unit_tests_timer.py | 4 +- tests/TestSuite_vf_daemon.py | 2 +- tests/TestSuite_vf_kernel.py | 2 +- .../TestSuite_virtio_ipsec_cryptodev_func.py | 2 +- tests/TestSuite_virtio_perf_cryptodev_func.py | 2 +- tests/TestSuite_virtio_unit_cryptodev_func.py | 2 +- tests/TestSuite_vm_hotplug.py | 2 +- tests/TestSuite_vm_power_manager.py | 2 +- tests/TestSuite_vm_pw_mgmt_policy.py | 2 +- tests/util/__init__.py | 2 +- tests/util/flow/__init__.py | 2 +- tests/util/virt/__init__.py | 2 +- tests/util/virt/qemu_kvm.py | 8 +- tests/util/virt/virt_base.py | 2 +- tests/util/virt/virt_common.py | 2 +- tests/util/virt/virt_dut.py | 3 +- tests/util/virt/virt_scene.py | 3 +- 45 files changed, 361 insertions(+), 312 deletions(-) diff --git a/framework/dut.py b/framework/dut.py index 83f0d7a2..74260c90 100644 --- a/framework/dut.py +++ b/framework/dut.py @@ -37,6 +37,7 @@ from typing import Dict, List, Optional, Union from uuid import uuid4 import framework.settings as settings +from framework.virt_resource import VirtResource from nics.net_device import GetNicObj from .config import AppNameConf, PortConf @@ -46,7 +47,6 @@ from .settings import LOG_NAME_SEP, NICS from .ssh_connection import SSHConnection from .test_result import ResultTable from .utils import RED, remove_old_rsa_key -from framework.virt_resource import VirtResource class Dut(Crb): diff --git a/tests/TestSuite_cvl_advanced_iavf_rss_pppol2tpoudp.py b/tests/TestSuite_cvl_advanced_iavf_rss_pppol2tpoudp.py index f47a3ae7..c6ee9699 100644 --- a/tests/TestSuite_cvl_advanced_iavf_rss_pppol2tpoudp.py +++ b/tests/TestSuite_cvl_advanced_iavf_rss_pppol2tpoudp.py @@ -1884,7 +1884,7 @@ vector_case_64 = [ }, ] -#l2tpv2 control + data +# l2tpv2 control + data vector_case_65 = [ { "sub_casename": "l2tpv2_session_id_MAC_IPV4_L2TPV2_CONTROL", @@ -1893,21 +1893,21 @@ vector_case_65 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -1919,21 +1919,21 @@ vector_case_66 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -1945,21 +1945,21 @@ vector_case_67 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -1971,21 +1971,21 @@ vector_case_68 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0xc80,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -1997,21 +1997,21 @@ vector_case_69 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2023,21 +2023,21 @@ vector_case_70 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2049,21 +2049,21 @@ vector_case_71 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2075,21 +2075,21 @@ vector_case_72 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2101,21 +2101,21 @@ vector_case_73 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2127,21 +2127,21 @@ vector_case_74 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2153,21 +2153,21 @@ vector_case_75 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2179,21 +2179,21 @@ vector_case_76 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2205,21 +2205,21 @@ vector_case_77 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2231,21 +2231,21 @@ vector_case_78 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2257,21 +2257,21 @@ vector_case_79 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2283,21 +2283,21 @@ vector_case_80 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2309,21 +2309,21 @@ vector_case_81 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2335,21 +2335,21 @@ vector_case_82 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=8,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2361,21 +2361,21 @@ vector_case_83 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2387,21 +2387,21 @@ vector_case_84 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2413,21 +2413,21 @@ vector_case_85 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2439,21 +2439,21 @@ vector_case_86 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2465,21 +2465,21 @@ vector_case_87 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x2222)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2491,21 +2491,21 @@ vector_case_88 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x2222)", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=12,session_id=0x1111)", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2517,21 +2517,21 @@ vector_case_89 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2543,21 +2543,21 @@ vector_case_90 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2569,21 +2569,21 @@ vector_case_91 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2595,21 +2595,21 @@ vector_case_92 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2621,21 +2621,21 @@ vector_case_93 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2647,21 +2647,21 @@ vector_case_94 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2673,21 +2673,21 @@ vector_case_95 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2699,21 +2699,21 @@ vector_case_96 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2725,21 +2725,21 @@ vector_case_97 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2751,21 +2751,21 @@ vector_case_98 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2777,21 +2777,21 @@ vector_case_99 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2803,21 +2803,21 @@ vector_case_100 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x000,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2829,21 +2829,21 @@ vector_case_101 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2855,21 +2855,21 @@ vector_case_102 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x400,len=12,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2881,21 +2881,21 @@ vector_case_103 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2907,21 +2907,21 @@ vector_case_104 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x080,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2933,21 +2933,21 @@ vector_case_105 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2959,21 +2959,21 @@ vector_case_106 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x2222,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x020,session_id=0x1111,offset=6)/Raw(b'\\x00\\x00\\x00\\x00')/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -2985,21 +2985,21 @@ vector_case_107 = [ "test": [ { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] @@ -3011,24 +3011,25 @@ vector_case_108 = [ "test": [ { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "save_hash" + "action": "save_hash", }, { "send_packet": "Ether(src='11:22:33:44:55:77')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_different" + "action": "check_hash_different", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IPv6()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x2222)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_hash_same" + "action": "check_hash_same", }, { "send_packet": "Ether(src='00:00:00:00:00:01')/IP()/UDP(dport=1701)/L2TP(hdr=0x480,len=16,session_id=0x1111)/HDLC()/Raw(b'\\x00\\x00')", - "action": "check_no_hash" + "action": "check_no_hash", }, - ] + ], }, ] + class TestCVLAdvancedIAVFRSSPPPoL2TPv2oUDP(TestCase): def set_up_all(self): """ @@ -3467,8 +3468,8 @@ class TestCVLAdvancedIAVFRSSPPPoL2TPv2oUDP(TestCase): ): self.switch_testpmd(symmetric=False) self.rssprocess.handle_rss_distribute_cases(cases_info=vector_case_64) - - #l2tpv2 control + data + + # l2tpv2 control + data def test_case_l2tpv2_session_id_MAC_IPV4_L2TPV2_CONTROL(self): self.switch_testpmd(symmetric=False) self.rssprocess.handle_rss_distribute_cases(cases_info=vector_case_65) diff --git a/tests/TestSuite_cvl_iavf_fdir_pppol2tpoudp.py b/tests/TestSuite_cvl_iavf_fdir_pppol2tpoudp.py index 85d455be..1d367aaf 100644 --- a/tests/TestSuite_cvl_iavf_fdir_pppol2tpoudp.py +++ b/tests/TestSuite_cvl_iavf_fdir_pppol2tpoudp.py @@ -30,18 +30,18 @@ # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -import re import random +import re import time from multiprocessing import Manager, Process +import framework.utils as utils +import tests.rte_flow_common as rfc from framework.packet import Packet from framework.pmd_output import PmdOutput from framework.test_case import TestCase - -import framework.utils as utils -import tests.rte_flow_common as rfc from framework.utils import GREEN, RED + from .rte_flow_common import CVL_TXQ_RXQ_NUMBER tv_l2tpv2_seession_id_mac_ipv4_l2tpv2_control = { @@ -80,7 +80,7 @@ vectors_mac_ipv4_l2tpv2_control = [ tv_l2tpv2_seession_id_mac_ipv4_l2tpv2_control, tv_eth_l2_src_only_mac_ipv4_l2tpv2_control, ] - + tv_l2tpv2_seession_id_mac_ipv6_l2tpv2_control = { "name": "l2tpv2_seession_id_mac_ipv6_l2tpv2_control", "rule": "flow create 0 ingress pattern eth / ipv6 / udp / l2tpv2 type control session_id is 0x1111 / end actions queue index 3 / end", @@ -113,7 +113,10 @@ tv_eth_l2_src_only_mac_ipv6_l2tpv2_control = { "check_param": {"port_id": 0, "drop": 1}, } -vectors_mac_ipv6_l2tpv2_control = [tv_l2tpv2_seession_id_mac_ipv6_l2tpv2_control,tv_eth_l2_src_only_mac_ipv6_l2tpv2_control] +vectors_mac_ipv6_l2tpv2_control = [ + tv_l2tpv2_seession_id_mac_ipv6_l2tpv2_control, + tv_eth_l2_src_only_mac_ipv6_l2tpv2_control, +] tv_l2tpv2_seession_id_mac_ipv4_l2tpv2_data = { "name": "l2tpv2_seession_id_mac_ipv4_l2tpv2_data", @@ -1609,7 +1612,7 @@ tv_ipv4_tcp_mac_ipv6_pppol2tpv2_ipv4_tcp_data_o = { "match": [ 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,offset=6)/Raw(b"\\x00\\x00\\x00\\x00")/HDLC()/Raw(b"\\x00\\x21")/IP(dst="10.0.0.22")/TCP(sport=11)', 'Ether(src="00:00:00:00:00:01")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,offset=6)/Raw(b"\\x00\\x00\\x00\\x00")/HDLC()/Raw(b"\\x00\\x21")/IP(dst="10.0.0.22")/TCP(sport=11)', - ], + ], "mismatch": [ 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,offset=6)/Raw(b"\\x00\\x00\\x00\\x00")/HDLC()/Raw(b"\\x00\\x21")/IP(dst="10.0.0.22")/TCP(sport=10)', 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x020,offset=6)/Raw(b"\\x00\\x00\\x00\\x00")/HDLC()/Raw(b"\\x00\\x21")/IP(dst="10.0.0.20")/TCP(sport=11)', @@ -1744,7 +1747,7 @@ tv_ipv6_udp_mac_ipv6_pppol2tpv2_ipv6_udp_pay_data = { "match": [ 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000)/HDLC()/Raw(b"\\x00\\x57")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=11)', 'Ether(src="00:00:00:00:00:01")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000)/HDLC()/Raw(b"\\x00\\x57")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=11)', - ], + ], "mismatch": [ 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000)/HDLC()/Raw(b"\\x00\\x57")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=10)', 'Ether(src="11:22:33:44:55:77")/IPv6()/UDP(dport=1701)/L2TP(hdr=0x000)/HDLC()/Raw(b"\\x00\\x57")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2022")/UDP(sport=11)', @@ -1829,7 +1832,7 @@ vectors_mac_ipv6_pppol2tpv2_ipv6_udp_pay = [ tv_ipv6_udp_mac_ipv6_pppol2tpv2_ipv6_udp_pay_data_o, tv_ipv6_udp_mac_ipv6_pppol2tpv2_ipv6_udp_pay_data_l_s, ] - + tv_ipv6_tcp_mac_ipv6_pppol2tpv2_ipv6_tcp_data = { "name": "ipv6_tcp_mac_ipv6_pppol2tpv2_ipv6_tcp_data", "rule": "flow create 0 ingress pattern eth / ipv6 / udp / l2tpv2 type data / ppp / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / tcp src is 11 / end actions queue index 3 / end", @@ -1923,8 +1926,8 @@ vectors_mac_ipv6_pppol2tpv2_ipv6_tcp = [ tv_ipv6_tcp_mac_ipv6_pppol2tpv2_ipv6_tcp_data_l_s, ] -class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): +class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): def rte_flow_process(self, vectors): test_results = {} for tv in vectors: @@ -1941,15 +1944,15 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): # send and check match packets out1 = self.send_pkts_getouput(pkts=tv["scapy_str"]["match"]) rfc.check_iavf_fdir_mark( - out1, - pkt_num=len(tv["scapy_str"]["match"]), + out1, + pkt_num=len(tv["scapy_str"]["match"]), check_param=tv["check_param"], ) # send and check mismatch packets out2 = self.send_pkts_getouput(pkts=tv["scapy_str"]["mismatch"]) rfc.check_iavf_fdir_mark( - out2, - pkt_num=len(tv["scapy_str"]["mismatch"]), + out2, + pkt_num=len(tv["scapy_str"]["mismatch"]), check_param=tv["check_param"], stats=False, ) @@ -1960,7 +1963,7 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): out3 = self.send_pkts_getouput(pkts=tv["scapy_str"]["match"]) rfc.check_iavf_fdir_mark( out3, - pkt_num=len(tv["scapy_str"]["match"]), + pkt_num=len(tv["scapy_str"]["match"]), check_param=tv["check_param"], stats=False, ) @@ -1992,17 +1995,19 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): self.ports_socket = self.dut.get_numa_id(self.dut_ports[0]) self.tester_port0 = self.tester.get_local_port(self.dut_ports[0]) self.tester_iface0 = self.tester.get_interface(self.tester_port0) - self.pci0 = self.dut.ports_info[self.dut_ports[0]]['pci'] - self.pf0_intf = self.dut.ports_info[self.dut_ports[0]]['intf'] + self.pci0 = self.dut.ports_info[self.dut_ports[0]]["pci"] + self.pf0_intf = self.dut.ports_info[self.dut_ports[0]]["intf"] - self.vf_driver = self.get_suite_cfg()['vf_driver'] + self.vf_driver = self.get_suite_cfg()["vf_driver"] if self.vf_driver is None: - self.vf_driver = 'vfio-pci' + self.vf_driver = "vfio-pci" self.used_dut_port_0 = self.dut_ports[0] - self.dut.generate_sriov_vfs_by_port(self.used_dut_port_0, 1, driver=self.kdriver) - self.sriov_vfs_port = self.dut.ports_info[self.used_dut_port_0]['vfs_port'] + self.dut.generate_sriov_vfs_by_port( + self.used_dut_port_0, 1, driver=self.kdriver + ) + self.sriov_vfs_port = self.dut.ports_info[self.used_dut_port_0]["vfs_port"] self.dut.send_expect( - 'ip link set %s vf 0 mac 00:11:22:33:44:55' % self.pf0_intf, '#' + "ip link set %s vf 0 mac 00:11:22:33:44:55" % self.pf0_intf, "#" ) self.vf0_pci = self.sriov_vfs_port[0].pci for port in self.sriov_vfs_port: @@ -2029,14 +2034,14 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): ) self.pmd_output.execute_cmd("set fwd rxonly") self.pmd_output.execute_cmd("set verbose 1") - res = self.pmd_output.wait_link_status_up('all', timeout=15) - self.verify(res is True, 'there have port link is down') - + res = self.pmd_output.wait_link_status_up("all", timeout=15) + self.verify(res is True, "there have port link is down") + def send_packets(self, packets, pf_id=0, count=1): self.pkt.update_pkt(packets) tx_port = self.tester_iface0 self.pkt.send_pkt(crb=self.tester, tx_port=tx_port, count=count) - + def send_pkts_getouput(self, pkts, pf_id=0, count=1): """ if pkt_info is True, we need to get packet infomation to check the RSS hash and FDIR. @@ -2075,13 +2080,15 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): raise Exception("unsupported rule type, only accept list or str") if check_stats: self.verify( - all(rule_list), "some rules validate failed, result %s" % rule_list, + all(rule_list), + "some rules validate failed, result %s" % rule_list, ) elif check_stats == False: self.verify( - not any(rule_list), "all rules should validate failed, result %s" % rule_list, + not any(rule_list), + "all rules should validate failed, result %s" % rule_list, ) - + def create_fdir_rule(self, rule, check_stats=None): p = re.compile(r"Flow rule #(\d+) created") rule_list = [] @@ -2104,14 +2111,16 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): raise Exception("unsupported rule type, only accept list or str") if check_stats: self.verify( - all(rule_list), "some rules create failed, result %s" % rule_list, + all(rule_list), + "some rules create failed, result %s" % rule_list, ) elif check_stats == False: self.verify( - not any(rule_list), "all rules should create failed, result %s" % rule_list, + not any(rule_list), + "all rules should create failed, result %s" % rule_list, ) - return rule_list - + return rule_list + def destroy_fdir_rule(self, rule_id, port_id=0): if isinstance(rule_id, list): for i in rule_id: @@ -2141,12 +2150,12 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): result = [i.group(1) for i in res] self.verify( sorted(result) == sorted(rule_list), - "check rule list failed. expect %s, result %s" + "check rule list failed. expect %s, result %s" % (rule_list, result), ) else: self.verify(not p.search(out), "flow rule on port %s is existed" % port_id) - + def destroy_vf(self): self.dut.send_expect("quit", "# ", 60) time.sleep(2) @@ -2154,10 +2163,10 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): def test_mac_ipv4_l2tpv2_control(self): self.rte_flow_process(vectors_mac_ipv4_l2tpv2_control) - + def test_mac_ipv6_l2tpv2_control(self): self.rte_flow_process(vectors_mac_ipv6_l2tpv2_control) - + def test_mac_ipv4_l2tpv2(self): self.rte_flow_process(vectors_mac_ipv4_l2tpv2) @@ -2172,16 +2181,16 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): def test_mac_ipv4_pppol2tpv2_ipv4_pay(self): self.rte_flow_process(vectors_mac_ipv4_pppol2tpv2_ipv4_pay) - + def test_mac_ipv4_pppol2tpv2_ipv4_udp_pay(self): self.rte_flow_process(vectors_mac_ipv4_pppol2tpv2_ipv4_udp_pay) - + def test_mac_ipv4_pppol2tpv2_ipv4_tcp(self): self.rte_flow_process(vectors_mac_ipv4_pppol2tpv2_ipv4_tcp) def test_mac_ipv4_pppol2tpv2_ipv6_pay(self): self.rte_flow_process(vectors_mac_ipv4_pppol2tpv2_ipv6_pay) - + def test_mac_ipv4_pppol2tpv2_ipv6_udp_pay(self): self.rte_flow_process(vectors_mac_ipv4_pppol2tpv2_ipv6_udp_pay) @@ -2215,4 +2224,3 @@ class TestCVLIAVFFDIRPPPoL2TPv2oUDP(TestCase): def tear_down_all(self): self.destroy_vf() self.dut.kill_all() - diff --git a/tests/TestSuite_ddp_gtp.py b/tests/TestSuite_ddp_gtp.py index 7b1b4f81..b7d08d12 100644 --- a/tests/TestSuite_ddp_gtp.py +++ b/tests/TestSuite_ddp_gtp.py @@ -35,8 +35,8 @@ import time import framework.utils as utils from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm VM_CORES_MASK = "all" diff --git a/tests/TestSuite_ddp_mpls.py b/tests/TestSuite_ddp_mpls.py index 0ab4cb6c..867bf2bf 100644 --- a/tests/TestSuite_ddp_mpls.py +++ b/tests/TestSuite_ddp_mpls.py @@ -33,8 +33,8 @@ import random import time from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm VM_CORES_MASK = "all" PF_MAX_QUEUE = 64 diff --git a/tests/TestSuite_eeprom_dump.py b/tests/TestSuite_eeprom_dump.py index dc665219..c1a5b4ea 100644 --- a/tests/TestSuite_eeprom_dump.py +++ b/tests/TestSuite_eeprom_dump.py @@ -74,14 +74,14 @@ class TestEEPROMDump(TestCase): # if nic is columbiaville, eeprom_dump get testpmd output of the first 1000 lines, # module_eeprom_dump get testpmd output of the first 16 lines. if self.nic in ["columbiaville_25g", "columbiaville_100g"]: - if testname == "eeprom": + if testname == "eeprom": count = 1000 elif testname == "module_eeprom": count = 16 - n=0 + n = 0 # Get testpmd output to have only hex value for line in re.findall(regex, get): - n= n+1 + n = n + 1 if n <= count: line = line.replace(" ", "").lower() self.dut.send_expect(f"echo {line} >> {to}", "#") @@ -98,7 +98,9 @@ class TestEEPROMDump(TestCase): for port in self.ports: # show port {port} eeprom has 10485760 bytes, and it takes about 13 minutes to show finish. - pmdout = self.dut.send_expect(f"show port {port} {testname}", "testpmd>", timeout=800) + pmdout = self.dut.send_expect( + f"show port {port} {testname}", "testpmd>", timeout=800 + ) self.verify("Finish --" in pmdout, f"{testname} dump failed") # get length from testpmd outout diff --git a/tests/TestSuite_ixgbe_vf_get_extra_queue_information.py b/tests/TestSuite_ixgbe_vf_get_extra_queue_information.py index 2fa2974f..c51dbfe8 100644 --- a/tests/TestSuite_ixgbe_vf_get_extra_queue_information.py +++ b/tests/TestSuite_ixgbe_vf_get_extra_queue_information.py @@ -36,11 +36,11 @@ Test Niantic ixgbe_get_vf_queue Include Extra Information function. import time from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm # Use scapy to send packets with different source and dest ip. # and collect the hash result of five tuple and the queue id. from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm class TestIxgbeVfGetExtraInfo(TestCase): diff --git a/tests/TestSuite_power_bidirection_channel.py b/tests/TestSuite_power_bidirection_channel.py index b8a5e028..f75d3abc 100644 --- a/tests/TestSuite_power_bidirection_channel.py +++ b/tests/TestSuite_power_bidirection_channel.py @@ -38,9 +38,9 @@ import time import traceback from framework.exception import VerifyFailure -from tests.util.virt.qemu_libvirt import LibvirtKvm from framework.test_case import TestCase from framework.utils import create_mask as dts_create_mask +from tests.util.virt.qemu_libvirt import LibvirtKvm class TestPowerBidirectionChannel(TestCase): diff --git a/tests/TestSuite_power_negative.py b/tests/TestSuite_power_negative.py index 2d98d8a6..c14f0b58 100644 --- a/tests/TestSuite_power_negative.py +++ b/tests/TestSuite_power_negative.py @@ -37,8 +37,8 @@ power negative test suite. import os import time -from tests.util.virt.qemu_libvirt import LibvirtKvm from framework.test_case import TestCase +from tests.util.virt.qemu_libvirt import LibvirtKvm class TestPowerNegative(TestCase): diff --git a/tests/TestSuite_rte_flow.py b/tests/TestSuite_rte_flow.py index 237a2559..566759e1 100644 --- a/tests/TestSuite_rte_flow.py +++ b/tests/TestSuite_rte_flow.py @@ -36,9 +36,9 @@ MTU Checks example. """ from typing import Callable -from tests.util.flow import generator from framework.pmd_output import PmdOutput from framework.test_case import TestCase +from tests.util.flow import generator class RteFlow(TestCase): diff --git a/tests/TestSuite_runtime_vf_queue_number.py b/tests/TestSuite_runtime_vf_queue_number.py index 99af8710..5d882e41 100644 --- a/tests/TestSuite_runtime_vf_queue_number.py +++ b/tests/TestSuite_runtime_vf_queue_number.py @@ -39,8 +39,8 @@ import time from framework.packet import Packet from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm RSS_KEY = "6EA6A420D5138E712433B813AE45B3C4BECB2B405F31AD6C331835372D15E2D5E49566EE0ED1962AFA1B7932F3549520FD71C75E" PACKET_COUNT = 100 diff --git a/tests/TestSuite_shutdown_api.py b/tests/TestSuite_shutdown_api.py index 9248447a..56361665 100644 --- a/tests/TestSuite_shutdown_api.py +++ b/tests/TestSuite_shutdown_api.py @@ -43,9 +43,9 @@ from random import randint import framework.utils as utils from framework.exception import VerifyFailure from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.settings import DRIVERS, HEADER_SIZE from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm # # diff --git a/tests/TestSuite_unit_tests_cmdline.py b/tests/TestSuite_unit_tests_cmdline.py index a1ff4d3d..20bde65e 100644 --- a/tests/TestSuite_unit_tests_cmdline.py +++ b/tests/TestSuite_unit_tests_cmdline.py @@ -59,7 +59,9 @@ class TestUnitTestsCmdline(TestCase): """ # icc compilation cost long long time. self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_crc.py b/tests/TestSuite_unit_tests_crc.py index b3ba6af2..84ec1dff 100644 --- a/tests/TestSuite_unit_tests_crc.py +++ b/tests/TestSuite_unit_tests_crc.py @@ -57,7 +57,9 @@ class TestUnitTestsCrc(TestCase): Run at the start of each test suite. """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_cryptodev_func.py b/tests/TestSuite_unit_tests_cryptodev_func.py index 7290c9ef..bd289fdb 100644 --- a/tests/TestSuite_unit_tests_cryptodev_func.py +++ b/tests/TestSuite_unit_tests_cryptodev_func.py @@ -40,7 +40,9 @@ class UnitTestsCryptodev(TestCase): def set_up_all(self): self._app_path = self.dut.apps_name["test"] cc.bind_qat_device(self, "vfio-pci") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): pass diff --git a/tests/TestSuite_unit_tests_dump.py b/tests/TestSuite_unit_tests_dump.py index bebb92de..5e288be3 100644 --- a/tests/TestSuite_unit_tests_dump.py +++ b/tests/TestSuite_unit_tests_dump.py @@ -66,7 +66,9 @@ class TestUnitTestsDump(TestCase): self.verify(len(self.dut_ports) >= 1, "Insufficient ports for testing") self.start_test_time = 60 self.run_cmd_time = 60 - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_eal.py b/tests/TestSuite_unit_tests_eal.py index 9c775535..52938b5e 100644 --- a/tests/TestSuite_unit_tests_eal.py +++ b/tests/TestSuite_unit_tests_eal.py @@ -65,7 +65,9 @@ class TestUnitTestsEal(TestCase): eal_params = self.dut.create_eal_parameters(cores=default_cores) app_name = self.dut.apps_name["test"] self.test_app_cmdline = app_name + eal_params - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_event_timer.py b/tests/TestSuite_unit_tests_event_timer.py index c1498082..d3e07191 100644 --- a/tests/TestSuite_unit_tests_event_timer.py +++ b/tests/TestSuite_unit_tests_event_timer.py @@ -66,7 +66,9 @@ class TestUnitTestEventTimer(TestCase): self.eventdev_timer_device_bus_id = "0000:0a:01.0" self.dut.bind_eventdev_port(port_to_bind=self.eventdev_timer_device_bus_id) - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_kni.py b/tests/TestSuite_unit_tests_kni.py index c076ac26..5c925546 100644 --- a/tests/TestSuite_unit_tests_kni.py +++ b/tests/TestSuite_unit_tests_kni.py @@ -64,7 +64,9 @@ class TestUnitTestsKni(TestCase): self.verify("Error" not in out, "Error loading KNI module: " + out) - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) # # diff --git a/tests/TestSuite_unit_tests_loopback.py b/tests/TestSuite_unit_tests_loopback.py index 8ced8979..0fd935d1 100644 --- a/tests/TestSuite_unit_tests_loopback.py +++ b/tests/TestSuite_unit_tests_loopback.py @@ -82,7 +82,9 @@ class TestUnitTestsLoopback(TestCase): self.tmp_path = "/tmp/test_pmd_perf.c" self.dut.send_expect("rm -fr %s" % self.tmp_path, "# ") self.dut.send_expect("cp app/test/test_pmd_perf.c %s" % self.tmp_path, "# ") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_lpm.py b/tests/TestSuite_unit_tests_lpm.py index bc8b85ac..5e46dbe9 100644 --- a/tests/TestSuite_unit_tests_lpm.py +++ b/tests/TestSuite_unit_tests_lpm.py @@ -61,7 +61,9 @@ class TestUnitTestsLpmIpv6(TestCase): Qos Prerequisites """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_mbuf.py b/tests/TestSuite_unit_tests_mbuf.py index 938dafca..62a21c9e 100644 --- a/tests/TestSuite_unit_tests_mbuf.py +++ b/tests/TestSuite_unit_tests_mbuf.py @@ -58,7 +58,9 @@ class TestUnitTestsMbuf(TestCase): Run at the start of each test suite. """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_mempool.py b/tests/TestSuite_unit_tests_mempool.py index 90f381a8..cd68f29c 100644 --- a/tests/TestSuite_unit_tests_mempool.py +++ b/tests/TestSuite_unit_tests_mempool.py @@ -58,7 +58,9 @@ class TestUnitTestsMempool(TestCase): Run at the start of each test suite. """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_pmd_perf.py b/tests/TestSuite_unit_tests_pmd_perf.py index 2cb57131..ee90f4dc 100644 --- a/tests/TestSuite_unit_tests_pmd_perf.py +++ b/tests/TestSuite_unit_tests_pmd_perf.py @@ -71,7 +71,9 @@ class TestUnitTestsPmdPerf(TestCase): self.anchors = ["rxtx", "rxonly", "txonly"] socket_id = self.dut.ports_info[0]["port"].socket self.cores = self.dut.get_core_list(config="1S/4C/1T", socket=socket_id) - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_power.py b/tests/TestSuite_unit_tests_power.py index ebe4b7c1..cce6e26a 100644 --- a/tests/TestSuite_unit_tests_power.py +++ b/tests/TestSuite_unit_tests_power.py @@ -59,7 +59,9 @@ class TestUnitTestsPower(TestCase): Power Prerequisites """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_qos.py b/tests/TestSuite_unit_tests_qos.py index 57e8b076..e8bb0743 100644 --- a/tests/TestSuite_unit_tests_qos.py +++ b/tests/TestSuite_unit_tests_qos.py @@ -60,7 +60,9 @@ class TestUnitTestsQos(TestCase): QoS Prerequisites """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_ring.py b/tests/TestSuite_unit_tests_ring.py index 9f448081..6c633223 100644 --- a/tests/TestSuite_unit_tests_ring.py +++ b/tests/TestSuite_unit_tests_ring.py @@ -58,7 +58,9 @@ class TestUnitTestsRing(TestCase): Run at the start of each test suite. """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_ringpmd.py b/tests/TestSuite_unit_tests_ringpmd.py index 7247d826..4befbc40 100644 --- a/tests/TestSuite_unit_tests_ringpmd.py +++ b/tests/TestSuite_unit_tests_ringpmd.py @@ -59,7 +59,9 @@ class TestUnitTestsRingPmd(TestCase): Nothing to do here. """ self.cores = self.dut.get_core_list("all") - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_unit_tests_timer.py b/tests/TestSuite_unit_tests_timer.py index 3a8d12d2..9d19f8c9 100644 --- a/tests/TestSuite_unit_tests_timer.py +++ b/tests/TestSuite_unit_tests_timer.py @@ -65,7 +65,9 @@ class TestUnitTestsTimer(TestCase): self.this_timeout = 60 if len(self.cores) > 16: self.this_timeout = self.this_timeout * len(self.cores) / 16 - self.logger.warning(f"Test Suite {self.__name__} is deprecated and will be removed in the next release") + self.logger.warning( + f"Test Suite {self.__name__} is deprecated and will be removed in the next release" + ) def set_up(self): """ diff --git a/tests/TestSuite_vf_daemon.py b/tests/TestSuite_vf_daemon.py index 1f119adf..6265a601 100644 --- a/tests/TestSuite_vf_daemon.py +++ b/tests/TestSuite_vf_daemon.py @@ -34,8 +34,8 @@ import time from framework.packet import Packet from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm VM_CORES_MASK = "all" MAX_VLAN = 4095 diff --git a/tests/TestSuite_vf_kernel.py b/tests/TestSuite_vf_kernel.py index 755f5741..5b3eaf89 100755 --- a/tests/TestSuite_vf_kernel.py +++ b/tests/TestSuite_vf_kernel.py @@ -44,9 +44,9 @@ import time import framework.utils as utils from framework.packet import Packet from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase from framework.utils import GREEN +from tests.util.virt.qemu_kvm import QEMUKvm class TestVfKernel(TestCase): diff --git a/tests/TestSuite_virtio_ipsec_cryptodev_func.py b/tests/TestSuite_virtio_ipsec_cryptodev_func.py index 00dc7558..9b5556cd 100644 --- a/tests/TestSuite_virtio_ipsec_cryptodev_func.py +++ b/tests/TestSuite_virtio_ipsec_cryptodev_func.py @@ -37,8 +37,8 @@ import binascii import framework.utils as utils import tests.cryptodev_common as cc from framework.packet import Packet -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm class VirtioCryptodevIpsecTest(TestCase): diff --git a/tests/TestSuite_virtio_perf_cryptodev_func.py b/tests/TestSuite_virtio_perf_cryptodev_func.py index d89cb024..27418037 100644 --- a/tests/TestSuite_virtio_perf_cryptodev_func.py +++ b/tests/TestSuite_virtio_perf_cryptodev_func.py @@ -34,8 +34,8 @@ Test DPDK vhost + virtio scenarios """ import tests.cryptodev_common as cc -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm class VirtioCryptodevPerfTest(TestCase): diff --git a/tests/TestSuite_virtio_unit_cryptodev_func.py b/tests/TestSuite_virtio_unit_cryptodev_func.py index 08cd03e3..28700354 100644 --- a/tests/TestSuite_virtio_unit_cryptodev_func.py +++ b/tests/TestSuite_virtio_unit_cryptodev_func.py @@ -35,8 +35,8 @@ Test DPDK vhost + virtio scenarios """ import tests.cryptodev_common as cc -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm class VirtioCryptodevUnitTest(TestCase): diff --git a/tests/TestSuite_vm_hotplug.py b/tests/TestSuite_vm_hotplug.py index b96d780c..5ff69cf0 100644 --- a/tests/TestSuite_vm_hotplug.py +++ b/tests/TestSuite_vm_hotplug.py @@ -41,8 +41,8 @@ import re import time from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.test_case import TestCase +from tests.util.virt.qemu_kvm import QEMUKvm VM_CORES_MASK = "all" diff --git a/tests/TestSuite_vm_power_manager.py b/tests/TestSuite_vm_power_manager.py index 2c6a37bc..bc4fb366 100644 --- a/tests/TestSuite_vm_power_manager.py +++ b/tests/TestSuite_vm_power_manager.py @@ -37,8 +37,8 @@ VM power manager test suite. import re import framework.utils as utils -from tests.util.virt.qemu_libvirt import LibvirtKvm from framework.test_case import TestCase +from tests.util.virt.qemu_libvirt import LibvirtKvm class TestVmPowerManager(TestCase): diff --git a/tests/TestSuite_vm_pw_mgmt_policy.py b/tests/TestSuite_vm_pw_mgmt_policy.py index 0f43f289..1710f619 100644 --- a/tests/TestSuite_vm_pw_mgmt_policy.py +++ b/tests/TestSuite_vm_pw_mgmt_policy.py @@ -47,9 +47,9 @@ from framework.exception import VerifyFailure from framework.packet import Packet from framework.pktgen import TRANSMIT_CONT from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_libvirt import LibvirtKvm from framework.test_case import TestCase from framework.utils import create_mask as dts_create_mask +from tests.util.virt.qemu_libvirt import LibvirtKvm class TestVmPwMgmtPolicy(TestCase): diff --git a/tests/util/__init__.py b/tests/util/__init__.py index 93e83aee..4ad62931 100644 --- a/tests/util/__init__.py +++ b/tests/util/__init__.py @@ -1,2 +1,2 @@ # SPDX-License-Identifier: BSD-3-Clause -# Copyright(c) 2022 University of New Hampshire \ No newline at end of file +# Copyright(c) 2022 University of New Hampshire diff --git a/tests/util/flow/__init__.py b/tests/util/flow/__init__.py index 93e83aee..4ad62931 100644 --- a/tests/util/flow/__init__.py +++ b/tests/util/flow/__init__.py @@ -1,2 +1,2 @@ # SPDX-License-Identifier: BSD-3-Clause -# Copyright(c) 2022 University of New Hampshire \ No newline at end of file +# Copyright(c) 2022 University of New Hampshire diff --git a/tests/util/virt/__init__.py b/tests/util/virt/__init__.py index 93e83aee..4ad62931 100644 --- a/tests/util/virt/__init__.py +++ b/tests/util/virt/__init__.py @@ -1,2 +1,2 @@ # SPDX-License-Identifier: BSD-3-Clause -# Copyright(c) 2022 University of New Hampshire \ No newline at end of file +# Copyright(c) 2022 University of New Hampshire diff --git a/tests/util/virt/qemu_kvm.py b/tests/util/virt/qemu_kvm.py index c6db1bb7..57285b2a 100644 --- a/tests/util/virt/qemu_kvm.py +++ b/tests/util/virt/qemu_kvm.py @@ -37,7 +37,13 @@ import time from framework.exception import StartVMFailedException from framework.settings import get_host_ip from framework.utils import RED, parallel_lock -from tests.util.virt.virt_base import ST_NOTSTART, ST_PAUSE, ST_RUNNING, ST_UNKNOWN, VirtBase +from tests.util.virt.virt_base import ( + ST_NOTSTART, + ST_PAUSE, + ST_RUNNING, + ST_UNKNOWN, + VirtBase, +) # This name is directly defined in the qemu guest service # So you can not change it except it is changed by the service diff --git a/tests/util/virt/virt_base.py b/tests/util/virt/virt_base.py index 4cc64565..9617fe1f 100644 --- a/tests/util/virt/virt_base.py +++ b/tests/util/virt/virt_base.py @@ -36,11 +36,11 @@ from random import randint import framework.exception as exception import framework.utils as utils - from framework.config import VIRTCONF, VirtConf from framework.dut import Dut from framework.logger import getLogger from framework.settings import CONFIG_ROOT_PATH + from .virt_dut import VirtDut ST_NOTSTART = "NOTSTART" diff --git a/tests/util/virt/virt_common.py b/tests/util/virt/virt_common.py index a0057ded..7fbd5583 100644 --- a/tests/util/virt/virt_common.py +++ b/tests/util/virt/virt_common.py @@ -31,9 +31,9 @@ import os from framework.config import VirtConf +from framework.settings import CONFIG_ROOT_PATH from tests.util.virt.qemu_kvm import QEMUKvm from tests.util.virt.qemu_libvirt import LibvirtKvm -from framework.settings import CONFIG_ROOT_PATH def VM(dut, vm_name, suite_name): diff --git a/tests/util/virt/virt_dut.py b/tests/util/virt/virt_dut.py index 8bbec12c..85c30390 100644 --- a/tests/util/virt/virt_dut.py +++ b/tests/util/virt/virt_dut.py @@ -34,13 +34,12 @@ import re import time import framework.settings as settings -from nics.net_device import GetNicObj, RemoveNicObj - from framework.config import AppNameConf, PortConf from framework.dut import Dut from framework.project_dpdk import DPDKdut from framework.settings import LOG_NAME_SEP, NICS, get_netdev, load_global_setting from framework.utils import RED, parallel_lock +from nics.net_device import GetNicObj, RemoveNicObj class VirtDut(DPDKdut): diff --git a/tests/util/virt/virt_scene.py b/tests/util/virt/virt_scene.py index 7dc7d45e..29b6625a 100644 --- a/tests/util/virt/virt_scene.py +++ b/tests/util/virt/virt_scene.py @@ -30,13 +30,12 @@ # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. import framework.utils as utils - from framework.config import VirtConf from framework.exception import * from framework.pmd_output import PmdOutput -from tests.util.virt.qemu_kvm import QEMUKvm from framework.settings import CONFIG_ROOT_PATH, get_netdev from framework.utils import create_mask +from tests.util.virt.qemu_kvm import QEMUKvm # scenario module for handling scenario # 1. load configurations -- 2.30.2