aboutsummaryrefslogtreecommitdiffstats
path: root/test
AgeCommit message (Collapse)AuthorFilesLines
2019-11-27tests: display stdout and stderr when output caching is disabledBenoît Ganne1-2/+2
Type: fix Change-Id: I4286ba58bb15dd67c1199f76166bedf3b4e0344c Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-11-27misc: add address sanitizer heap instrumentationBenoît Ganne1-0/+3
Introduce AddressSanitizer support: https://github.com/google/sanitizers/ This starts with heap instrumentation. vlib_buffer, bihash and stack instrumentation should follow. Type: feature Change-Id: I7f20e235b2f79db72efd0e756f22c75f717a9884 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-11-26fib: Fix crash on cover update to non activated adj sourceNeale Ranns2-0/+65
if the adj source is not active then there is no existing cover during a cover update Type: fix Ticket: VPP-1803 Signed-off-by: Neale Ranns <nranns@cisco.com> Change-Id: Ie912f1c99345de4fb012bdcd97b443098d4a7351
2019-11-26fib: Table ReplaceNeale Ranns7-48/+337
Type: feature from the API doc, a table replace is: " The use-case is that, for some unspecified reason, the control plane has a very different set of entries it wants in the table than VPP currently has. The CP would thus like to 'replace' VPP's current table only by specifying what the new set of entries shall be, i.e. it is not going to delete anything that already eixts. the CP delcartes the start of this procedure with this begin_replace API Call, and when it has populated all the entries it wants, it calls the below end_replace API. From this point on it is of coursce free to add and delete entries as usual. The underlying mechanism by which VPP implements this replace is purposefully left unspecified. " In the FIB, the algorithm is implemented using mark and sweep. Algorithm goes: 1) replace_begin: this marks all the entries in that table as 'stale' 2) download all the entries that should be in this table - this clears the stale flag on those entries 3) signal the table converged: ip_table_replace_end - this removes all entries that are still stale this procedure can be used when an agent first connects to VPP, as an alternative to dump and diff state reconciliation. Change-Id: I168edec10cf7670866076b129ebfe6149ea8222e Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-25tests: fix typo in test_vlibPaul Vinciguerra1-3/+3
Trailing comma made last line of a multi-line command a new command. Logs: 22:39:49,695 Return value: cli_inband_reply(_0=794, context=2, retval=0, reply='loop0\n') 22:39:49,695 CLI: packet-generator new { name vlib limit 15 size 128-128 interface loop0 node ethernet-input data { IP6: 00:d0:2d:5e:86:85 -> 00:0d:ea:d0:00:00 ICMP: db00::1 -> db00::2 incrementing 30 } 22:39:49,695 Calling cli_inband('cmd':'packet-generator new {\n name vlib\n limit 15\n size 128-128\n interface loop0\n node ethernet-input\n data {\n IP6: 00:d0:2d:5e:86:85 -> 00:0d:ea:d0:00:00\n ICMP: db00::1 -> db00::2\n incrementing 30\n }\n\n','context':3,'_vl_msg_id':792) 22:39:49,696 Return value: cli_inband_reply(_0=794, context=3, retval=0, reply='') 22:39:49,696 CLI: } 22:39:49,696 Calling cli_inband('cmd':'}\n\n','context':4,'_vl_msg_id':792) 22:39:49,697 Return value: cli_inband_reply(_0=794, context=4, retval=-1, reply="unknown inpu... 22:39:49,697 } FAIL reply unknown input `}' Type: fix Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com> Change-Id: Iaa82d432677d742e766e42383364adda5bd87665
2019-11-20vlib: improve code coverage, part deuxDave Barach1-0/+18
Type: test Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: If31f4b50da7a6e4a9704ceb3415c582143c08355
2019-11-18vlib: improve code coverage in src/vlibDave Barach1-0/+29
Type: test Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I2dc4c09730f77931a2b484a6dd5dc669068f8e57
2019-11-15tests: Add UT to test incomplete MPLS adjacencies send ARP requestsNeale Ranns1-3/+42
Type: test Change-Id: I81e07233aec54c786e4e9beb8c4f06d0a3dca90f Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-15tests: Remove the unrequired VPP IP address/prefix class wrappersNeale Ranns12-281/+147
Type: refactor Change-Id: I204f3f8eebc5f5d5a377e91262f91c615fd00168 Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-13vlib: improve vlib "make test" code coverageDave Barach1-0/+114
Type: test Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: Idf982fddad9e577595d2e05ac78c39705e9d616d
2019-11-12interface: Allow VLAN tag-rewrite on non-sub-interfaces too.Jon Loeliger1-0/+50
This fix was first made in commit fdea5c6a00b74971dbb1b7ec4e25839a871006ca but was subsequently lost in commit 053204ab039d34a990ff0e14c32ce3b294fcce0e Added unit test for setting VTR on a non-sub-interface to help ensure no future regressions of this ability. Type: fix Change-Id: I71ce2684fb72383741455829ae2d397ea2e95eae Signed-off-by: Jon Loeliger <jdl@netgate.com>
2019-11-12ip: IP address and prefix types (moved from LISP)Neale Ranns1-0/+20
Type: refactor Change-Id: I2c6b59013bfd21136a2955442c779685f951932b Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-11ip: functional interface to ip fragmentationOle Troan2-2/+49
This provides a functional interface to IP fragmentation. Allowing external features to fragment. Supports arbitrary encap size, for e.g. MPLS or inner fragmentation of tunnels. This also removed dual loop in MAP that was fundamentally broken. Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Ia89ecec8ee3cbe2416edbe87630fdb714898c2a8 Signed-off-by: Ole Troan <ot@cisco.com>
2019-11-08ipsec: remove dedicated IPSec tunnelsNeale Ranns9-79/+131
APIs for dedicated IPSec tunnels will remain in this release and are used to programme the IPIP tunnel protect. APIs will be removed in a future release. see: https://wiki.fd.io/view/VPP/IPSec Type: feature Change-Id: I0f01f597946fdd15dfa5cae3643104d5a9c83089 Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-08tests: python3 use byte strings in raw()Ole Troan13-69/+69
Raw('\xaf) and Raw(b'\xaf) are two quite different things in python 2 versus 3. In most cases this didn't make a difference, apart from those cases where length of payload actually mattered. Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I3cba5c1486e436a3ca8aa10a7b393da75aa9f6b9
2019-11-07interface: shmemioerror while getting name_filter argAleksander Djuric1-1/+6
Type: fix Signed-off-by: Aleksander Djuric <aleksander.djuric@gmail.com> Change-Id: I5e0eb7024d208040d79e9d6db863f41e2ecf4ee6 Signed-off-by: Ole Troan <ot@cisco.com>
2019-11-07tests: make threads in punt tests join when finishedAndrew Yourtchenko1-8/+23
The 42693521f6046997133c8f63bcfc9d615d96f69d added the timeout to the child process join + print the name of the offending child process. Upon testing the issue furher, appeared the offenders were always the same - punt tests. The processes running them were stuck trying to acquire lock, even if all the user-accessible execution has finished. Some searching revealed that one needs to tread carefully when dealing with Thread and Multiprocessing at the same time. punt tests used threads but did not call thread.join. Somehow it worked in some cases but not the others. This fix makes the threads exit cleanly - which also makes the timeouts waiting for the process to join disappear. Type: test Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com> Change-Id: I05d99bb48a9987544bbfe45118755c09d7867aa0 Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2019-11-05misc: Fix python scripts shebang lineRenato Botelho do Couto75-75/+75
Type: fix Since CentOS 8, RPM build script doesn't accept '#!/usr/bin/env python' as a valid shebang line. It requires scripts to explicitly chose between python2 or python3. Change all to use python3 as suggested by Paul Vinciguerra. Depends-On: https://gerrit.fd.io/r/23170 Signed-off-by: Renato Botelho do Couto <renato@netgate.com> Change-Id: Ie72af9f60fd0609e07f05b70f8d96e738b2754d1
2019-11-05ip: Fragmentation fixesNeale Ranns4-6/+34
Type: fix if the packet is about to be fragmented, then don't call any of the actions that expect the rewrite to have been written. 1) don't double count packets thru the adjacency (original & fragments) 2) don't double decrement the TTL for fragments 3) return to ip4-midchain post ip-frag if that's where we started. 4) only run midchain/mcast fixups if not fragmenting (if no errors) Change-Id: Ib2866787a42713ee5871b87b597d8f74b901044b Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-11-05tests: support setting random seedKlement Sekera4-1/+13
Log the random seed used when running tests and provide means to re-use it in a later run. Type: feature Change-Id: I18d2a36ee802b901d4cca5577df41cec07f09cc0 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2019-11-05tests: avoid test runner hanging on child test process joinAndrew Yourtchenko1-1/+13
In parallel test, the single process is spawning a bunch of child processes running the tests, and communicates to them. When the child process signals that it has finished, the parent calls child.join(). Sometimes this join never returns. The result is a lot of defunct python processes, and the test run just hangs. I have seen this failure intermittently a fair bit in a busy containerized environment, and by chance, consistently reproduced it on a Thinkpad X280 with 8G of RAM and Ubuntu 19.04, which allowed to diagnose it. Type: test Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com> Change-Id: If0a3110fc2d23e73d77c310d61c3ea90a2b53610
2019-10-31tests: Revert "tests: add sending SIGQUIT to vpp quit sequence"Andrew Yourtchenko1-7/+6
This reverts commit 4465fe1e30556b40c9ef8a1a155aa1665102dd22. That commit makes *every* test to send SIGQUIT to VPP when it is done, thereby triggering the coredump if there was none. It is most surely not what we want. Type: test Change-Id: I3cc4c96f44c05527d586142f8feccc2f93c3e536 Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2019-10-30tests: add sending SIGQUIT to vpp quit sequencePaul Vinciguerra1-6/+7
As suggested in the docs by: https://fd.io/docs/vpp/master/usecases/contiv/core_files#let-vpp-crash Type: test Change-Id: I10caf16220e2507351636c1b26e57e19bcf8a542 Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2019-10-30l2: l2tp API cleanupJakub Grajciar1-3/+2
Use consistent API types. Type: fix Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com> Change-Id: I9015fc60e8d77e5d5ac36bf2862c1fe794addb81 Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2019-10-29tests: decode worker stdout/stderr outputDave Wallace1-2/+2
Type: fix Signed-off-by: Dave Wallace <dwallacelf@gmail.com> Change-Id: I309254e9e99920fbeaa50eea503c1c2a9470abfe
2019-10-29tests: fix TEST= filtering for python3Klement Sekera1-1/+1
Type: fix Change-Id: Iceb60e8a507120434cfc68758476ff5351b05f58 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2019-10-28tests: switch test framework to python3 by defaultOle Troan2-7/+7
Type: make Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I84d32f022d9dc555837c8916feba04a224cd262a
2019-10-28tests: make RA tests run on VPP timeAndrew Yourtchenko2-7/+21
the IPv6 RA tests take timing into the account, but the time inside VPP may go slightly differently compared to the time inside the driving python thread, if the machine running the tests is heavily loaded. Make a sleep function which sleeps "on VPP time" and use it. Change-Id: I3b34b0164f6e0ec7a619b92ee308089a4a8935e3 Type: test Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2019-10-26l2: l2bd nd termination test instabilityOle Troan1-1/+1
The test for ND event suppression reused the previous test run ipv6 address, and would sometimes consider that a duplicate, and therefore suppressing that one too. Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I1b115aa4eba9d57770fa03fcf38b7a1c251cfe88
2019-10-23cdp: re-enable skipped tests for python3Ole Troan1-3/+10
CDP uses the running sytems host name, which caused different failures on different systems. The root cause was an python3 specific error in checksum calculation. Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I205436682d46e7e8cbb8c057c03a76dbbcab4d72
2019-10-22tests: test tls casehaiyanx1.zhang1-0/+145
Type: feature Signed-off-by: haiyanx1.zhang <haiyanx1.zhang@intel.com> Change-Id: I071f5face0d489dc967cce1edcffbc1f8fac5c7e Signed-off-by: haiyanx1.zhang <haiyanx1.zhang@intel.com>
2019-10-22tests: DEBUG=gdb[server]-all to debug worker(s)Dave Wallace2-13/+74
Type: test Signed-off-by: Dave Wallace <dwallacelf@gmail.com> Change-Id: I0264451632c1ce780b38a2c15a7e34350fc6d521
2019-10-21geneve: tests support python3Ole Troan1-1/+1
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I0ff4d58c181b2bdf483b8b039ad005c2a4915aa8
2019-10-21bonding: tests support python3Ole Troan1-2/+2
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I6cedb43af4437fdabce75f4a845629c5c2f96f6a
2019-10-21ip: test support python3Ole Troan1-33/+33
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I9c66bce900f78e5fbd435515df94e327ad25c3c6
2019-10-21l2: tests support python3Ole Troan2-2/+2
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Id17bcb65d7eb27f865fc7872b3e485c09f1d29a7
2019-10-21ipsec: tests support python3Ole Troan1-4/+4
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Id13da9371c71c10c12a0120ec89ba21c1ca47524
2019-10-21classify: tests to support python3Ole Troan2-5/+12
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I8af6ee6e5239f0836978baa063a18a01c610279f
2019-10-21bier: tests support python3Ole Troan1-1/+1
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I3cf5295f1a85579a66ba38ca1f74678b45474959
2019-10-21tests: add PID of VPP under test to API dump filename for the testAndrew Yourtchenko1-1/+2
Some testclasses (e.g. IPSec) have methods with the same names, this causes a race when running in parallel to save the API and move it into the test's directory - the name of the file has only the test method name as a discriminator. Saving two traces from two VPP instances "succeeds", in that it silently overwrites the file. But only one mv operation works - the other gives an error "file not found" and fails the test. Solution: add the PID of VPP under test to the API dump filename, this way the filenames become guaranteed unique and the race is avoided. Change-Id: I1bb47ed73369fea0f1bfbf907588a51e2cabfb7f Type: test Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2019-10-21ip: reassembly tests python3 supportOle Troan1-16/+13
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I990d8d521c128e8d4f482e30b3a49cbc11b632d1
2019-10-18ip: add python3 support to punt testsOle Troan1-77/+50
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Ib918d11fb3278a25a92006dcfe3c7c484e7b33ea
2019-10-18gso: python3 support in testsOle Troan1-5/+5
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I166019cc69fd01cb43f1a3fad699f3d2e5ec5b19
2019-10-18ip: ip vrf tests python3 supportOle Troan2-8/+2
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Ie23c9d2d7325be62ef33df2f0562ab41518f7bf4
2019-10-18udp:: support python3 in testsOle Troan1-2/+2
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Iea19d7bc2dfe9736ddefb4419509ccfda7a67eeb
2019-10-18ipsec: make tests support python3Ole Troan3-25/+25
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I3255702e7c562c8d04a91a095e245756c6443a9e
2019-10-17tests: python3 changes for span and aclplugin testsnaramre1-1/+1
Type: fix Change-Id: Ia9f74f951f831cc5c9b5af863db1bb3f7a1a81ff Signed-off-by: snaramre <snaramre@cisco.com>
2019-10-17classify: make tests support python3Ole Troan2-7/+6
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I7c4a12165fa0928fb2b8d99fc1c8d5de16377e7e
2019-10-17tests: python3 fixes for reassembly testssnaramre1-4/+4
Type: fix Change-Id: I0d9b823bd558c48b18af9b0d1e80c30729e64dac Signed-off-by: snaramre <snaramre@cisco.com>
2019-10-17nat: tests support python3Ole Troan1-1/+1
Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: Ie15ea8f01846f87cb65e90e8762dc941441fc176