l2fwd Test Suite

Basic L2 forwarding test suite.

This testing suites runs basic L2 forwarding on testpmd across multiple different queue sizes. The forwarding test is performed with several packets being sent at once.

class TestL2fwd

Bases: TestSuite

L2 forwarding test suite.

NUMBER_OF_PACKETS_TO_SEND = 50

The total number of packets to generate and send for forwarding.

PAYLOAD_SIZE = 100

The payload size to use for the generated packets in bytes.

set_up_suite() None

Set up the test suite.

Setup:

Generate the random packets that will be sent.

l2fwd_integrity() None

Test the L2 forwarding integrity.

Test:

Configure a testpmd shell with a different numbers of queues (1, 2, 4 and 8) per run. Start up L2 forwarding, send random packets from the TG and verify they were all received back.