2.87. test_lisp module

class test_lisp.Driver(test, test_cases)

Bases: object

config_order = ['locator-sets', 'locators', 'local-mappings', 'remote-mappings', 'adjacencies']

Basic class for data driven testing

create_packet(src_if, dst_if, deid, payload='')

Create IPv4 packet

param: src_if param: dst_if

abstract run()

testing procedure

property test
property test_cases
class test_lisp.ForeignAddressFactory

Bases: object

count = 0
get_ip4()
net = '10.10.10.0/24'
net_template = '10.10.10.{}'
prefix_len = 24
class test_lisp.LISP_GPE_Header(*args: Any, **kwargs: Any)

Bases: scapy.packet.Packet

fields_desc = [scapy.fields.FlagsField, scapy.fields.BitField, scapy.fields.ByteField, scapy.fields.IntField]
name = 'LISP GPE Header'
class test_lisp.SimpleDriver(test, test_cases)

Bases: test_lisp.Driver

Implements simple test procedure

configure_tc(tc)
run(dest)

Send traffic for each test case and verify that it is encapsulated

verify_capture(src_loc, dst_loc, capture)

Verify captured packet

Parameters
  • src_loc – source locator address

  • dst_loc – destination locator address

  • capture – list of captured packets

class test_lisp.TestLisp(methodName='runTest')

Bases: framework.VppTestCase

Basic LISP test

setUp()

Clear trace before running each test

classmethod setUpClass()

Perform class setup before running the testcase Remove shared memory files, start vpp and connect the vpp-api

classmethod tearDownClass()

Perform final cleanup after running all tests in this test-case

test_lisp_basic_encap()

Test case for basic encapsulation

class test_lisp.TestLispUT(methodName='runTest')

Bases: framework.VppTestCase

Lisp UT

classmethod setUpClass()

Perform class setup before running the testcase Remove shared memory files, start vpp and connect the vpp-api

classmethod tearDownClass()

Perform final cleanup after running all tests in this test-case

test_fib()

LISP Unit Tests