From: <nareddy@marvell.com>
To: <dts@dpdk.org>
Cc: <pvukkisala@marvell.com>, Praneeth Reddy <nareddy@marvell.com>
Subject: [dts] [PATCH] TestSuite_shutdown_api.py: added new test case test_check_rxtx_desc_status
Date: Mon, 16 Mar 2020 09:51:52 +0530 [thread overview]
Message-ID: <1584332512-26301-1-git-send-email-nareddy@marvell.com> (raw)
From: Praneeth Reddy <nareddy@marvell.com>
Added new test case to verify descriptor status for cavium_a063 and cavium_a064
Signed-off-by: Praneeth Reddy <nareddy@marvell.com>
---
conf/test_case_supportlist.json | 16 ++++++++++++++++
tests/TestSuite_shutdown_api.py | 22 ++++++++++++++++++++++
2 files changed, 38 insertions(+)
diff --git a/conf/test_case_supportlist.json b/conf/test_case_supportlist.json
index 8d30513..eba0840 100644
--- a/conf/test_case_supportlist.json
+++ b/conf/test_case_supportlist.json
@@ -1766,5 +1766,21 @@
"Bug ID": "",
"Comments": "this case only support on fortville"
}
+ ],
+ "check_rxtx_desc_status": [
+ {
+ "OS": [
+ "ALL"
+ ],
+ "NIC": [
+ "cavium_a064",
+ "cavium_a063"
+ ],
+ "Target": [
+ "ALL"
+ ],
+ "Bug ID": "",
+ "Comments": "This case currently support for cavium_a063 and cavium_a064 "
+ }
]
}
diff --git a/tests/TestSuite_shutdown_api.py b/tests/TestSuite_shutdown_api.py
index 11d451b..6393b1d 100644
--- a/tests/TestSuite_shutdown_api.py
+++ b/tests/TestSuite_shutdown_api.py
@@ -40,12 +40,14 @@ import utils
import time
import re
import os
+import random
from test_case import TestCase
from pmd_output import PmdOutput
from settings import HEADER_SIZE, PROTOCOL_PACKET_SIZE
from exception import VerifyFailure
from qemu_kvm import QEMUKvm
from settings import get_nic_name
+from random import randint
#
#
@@ -744,6 +746,26 @@ class TestShutdownApi(TestCase):
self.check_ports(status=True)
self.check_forwarding()
+ def test_check_rxtx_desc_status(self):
+ """
+ Check tx and rx descriptors status.
+ """
+ self.pmdout.start_testpmd("Default", "--portmask=%s --port-topology=loop" % utils.create_mask(self.ports), socket=self.ports_socket)
+
+ for i in range(3):
+ self.desc = randint(0, 4095)
+ out = self.dut.send_expect("show port %s rxq 0 desc %s status" % (self.ports[0], self.desc), "testpmd> ")
+ self.verify(
+ "Desc status = AVAILABLE" in out, "RX descriptor status is improper")
+ self.verify(
+ "Bad arguments" not in out, "RX descriptor status is not supported")
+ self.desc = randint(0, 511)
+ out = self.dut.send_expect("show port %s txq 0 desc %s status" % (self.ports[0], self.desc), "testpmd> ")
+ self.verify(
+ "Desc status = FULL" in out, "TX descriptor status is improper")
+ self.verify(
+ "Bad arguments" not in out, "TX descriptor status is not supported")
+
def tear_down(self):
"""
Run after each test case.
--
1.8.3.1
next reply other threads:[~2020-03-16 4:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-16 4:21 nareddy [this message]
2020-03-20 8:06 ` Tu, Lijuan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1584332512-26301-1-git-send-email-nareddy@marvell.com \
--to=nareddy@marvell.com \
--cc=dts@dpdk.org \
--cc=pvukkisala@marvell.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).