Commit Graph

1047 Commits

Author SHA1 Message Date
Donald Sharp
ddbda04e87
Merge pull request #7909 from pjdruddy/snmp-skip-test
test: add snmp skip test
2021-01-22 08:23:56 -05:00
Donald Sharp
f95224c170
Merge pull request #7902 from opensourcerouting/topotest-marker
tests: Standardized Topotest PyTest Markers
2021-01-22 08:23:02 -05:00
Pat Ruddy
fd9f7cacf4 test: add snmp skip test
Since SNMP is a pain to install add a check which will be used
in all SNMP tests in future to silently skip SNMP tests if SNMP
has not been installed on the base system.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
2021-01-22 10:12:47 +00:00
Martin Winter
82b844d8d3
Merge pull request #7765 from gpnaveen/ospf_chaos_test
tests : Adding 3 ospf chaos testcases.
2021-01-21 23:59:29 +01:00
David Schweizer
6bd548aa49
tests: pytest markers in topotest templates
Signed-off-by: David Schweizer <dschweizer@opensourcerouting.org>
2021-01-21 17:06:58 +01:00
David Schweizer
309638adb5
tests: pytest marker registrations for all daemons
Signed-off-by: David Schweizer <dschweizer@opensourcerouting.org>
2021-01-21 16:24:02 +01:00
Donald Sharp
8cf7ab7539
Merge pull request #7782 from kuldeepkash/multicast_pim_sm_topo2
tests: Add new scenarios to test multicast-pim-sm
2021-01-21 09:45:38 -05:00
nguggarigoud
a3276d2c76 tests: Adding 3 ospf chaos testcases.
This script involves Restart ospfd,
restart frr with ospf enabled,
staticd with redistribution inside ospf is enabled

Signed-off-by: nguggarigoud <nguggarigoud@vmware.com>
2021-01-21 04:55:58 +05:30
Donatas Abraitis
44ba9e779d
Merge pull request #7832 from pjdruddy/snmp-test-infra
Snmp test infra
2021-01-20 09:15:14 +02:00
Mark Stapp
bdbef5edc6
Merge pull request #7233 from donaldsharp/route_map_optimizations
Route map optimizations
2021-01-19 13:20:02 -05:00
Russ White
4c35f214b7
Merge pull request #6455 from GalaxyGorilla/bfd_ospf_topotest
tests: Introduce BFD OSPFv2/v3 topotests
2021-01-19 07:39:05 -05:00
kuldeepkash
693a44e183 tests: Add new scenarios to test multicast-pim-sm(different topology)
Add new scenarios to test multicast-pim-sm(different topology)

Signed-off-by: kuldeepkash <kashyapk@vmware.com>
2021-01-18 20:09:07 +00:00
kuldeepkash
eab72dc8e0 tests: Add/enhance framework for multicast-pim-sm automation
1. Add/enhance framework for multicast-pim-sm automation

Signed-off-by: kuldeepkash <kashyapk@vmware.com>
2021-01-18 20:09:07 +00:00
kuldeepkash
c9b5d52c65 tests: Add new scenarios to test multicast-pim-sm
1, Added new scenarios to test multicast-pim-sm

Signed-off-by: kuldeepkash <kashyapk@vmware.com>
2021-01-18 20:08:53 +00:00
Donatas Abraitis
fba9c8d2fd
Merge pull request #7874 from donaldsharp/more_pytest_mark
More pytest mark
2021-01-18 10:12:24 +02:00
Donald Sharp
e1713aa16d tests: Set default timers to 3/10 for bgp using create_router_bgp
Tests were timing out in our test system due to lost packets and
flakiness of the lower end systems.  Just set the timers to 3/10
and give them plenty of time to converge.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-16 08:29:49 -05:00
Donald Sharp
fed1681178 tests: Modify zebra_rib tests to include some basic route-map tests
New test does this:
a) Ensures that we run the correct number of times given two
`ip protocol X` commands( ie we do not run the route-map application
against all routes, only those affected )
b) Ensure that when we modify the route-map the state ends up sane
this includes making a static route depend on a sharp route that
gets removed from the change of the sharp route-map
c) Ensure that the kernel routes are correct.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-15 19:34:33 -05:00
Donald Sharp
3771ded194 tests: Add pytest.mark.pbr
Add a mark to topotests that mark pbr tests

`pytest -k pbr`

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-15 09:18:59 -05:00
Donald Sharp
3914e57591 tests: Add pytest.mark.isis
Add a mark to topotests that mark isis tests

`pytest -k isis`

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-15 09:17:53 -05:00
Donald Sharp
1d0c76b74d tests: Add pytest.mark.bfd
Add a mark to topotests that mark bfd tests.

`pytest -k bfd`

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-15 08:58:24 -05:00
Mark Stapp
ea8885d54e
Merge pull request #7870 from donaldsharp/pytest_marking
tests: Start the ability to mark tests
2021-01-15 08:44:51 -05:00
Donatas Abraitis
2f8e365008 tests: Check if peer-group is working in topotests
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-01-15 11:35:57 +02:00
Donald Sharp
b9f3e47f3a tests: Start the ability to mark tests
Add the ability for our topotests to take advantage of pytest `mark`ing.
This effectively allows you to tell pytest to run against certain sets
of tests.  For a demonstration purpose I've added in marks for:
babel
eigrp
ldp
ospf
pim
rip

And setup tests to run against those tests that only test those protocols.

You can run against eigrp tests by running `pytest -k eigrp`
Other combinations are also available based upon simple boolean logic.
Just read the pytest.mark documentation.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-14 20:29:14 -05:00
Donald Sharp
f2aee6967c
Merge pull request #7837 from ckishimo/tests_ospf
tests: fix redistribute key in ospf tests
2021-01-13 13:31:32 -05:00
Donatas Abraitis
26542c7138
Merge pull request #7849 from gpnaveen/static_rte_test
tests: Static route cases with admin dist and tag.
2021-01-13 09:09:38 +02:00
Donatas Abraitis
6f860c4618
Merge pull request #7748 from adrianomarto/bgp-listen-on-multiple-addresses
BGP daemon listen for connections on multiple addresses
2021-01-13 08:57:38 +02:00
Pat Ruddy
b300ed94b1 tests: sample snmp test to check infra
Simple test which creates a router running snmp and bgpd and
checks we can read the correct bgpVersion using snmp.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
2021-01-12 19:59:56 +00:00
Olivier Dugeon
4683138cda
Merge pull request #7707 from opensourcerouting/isisd-rlfa
isisd, ldpd: add Remote LFA support
2021-01-12 19:25:15 +01:00
Donald Sharp
484eabb1d7
Merge pull request #7439 from opensourcerouting/bgp-damp-profile2
bgpd: BGP route-flap dampening profiles for peers and peer groups
2021-01-12 11:45:41 -05:00
Russ White
bc560f64d9
Merge pull request #7687 from gpnaveen/ospf_p2mp
tests: Adding ospf p2mp basic test.
2021-01-12 08:03:33 -05:00
nguggarigoud
26bbe9af5e tests: Static route cases with admin dist and tag.
1. Adding api to verify ip nht command.
2. 5 cases of static routes with admin dist and tag
3. Run time = 89Secs

Signed-off-by: nguggarigoud <nguggarigoud@vmware.com>
2021-01-12 17:13:26 +05:30
ckishimo
88b7d3e726 tests: move redistribute function into lib
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
2021-01-12 11:18:22 +01:00
ckishimo
9458be1aec tests: fix ospf cosmetic output
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
2021-01-12 11:18:22 +01:00
ckishimo
65980a0224 tests: remove old def for redistribution in ospf
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
2021-01-12 11:18:22 +01:00
ckishimo
c6b59ef48c tests: use new def for redistribution in ospf
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
2021-01-12 11:18:22 +01:00
ckishimo
881fa68f05 tests: add new def for redistribution in ospf
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
2021-01-12 11:18:22 +01:00
nguggarigoud
dc5298d741 tests: Adding ospf p2mp basic test.
This test verifies basic p2mp test

Signed-off-by: nguggarigoud <nguggarigoud@vmware.com>
2021-01-12 09:28:50 +05:30
Babis Chalios
daee3312bf tests: add machinery to test SNMP
Add initial 'walk' and 'get' test APIs for SNMP

Signed-off-by: Babis Chalios <babis@voltanet.io>
Signed-off-by: Pat Ruddy <pat@voltanet.io>
2021-01-11 14:36:41 +00:00
Babis Chalios
92be50e63e tests: API to launch snmpd in a topotest scenario
Prepare the infrastructure to allow configuring and launching an SNMP
daemon as part of testing scenario.

Signed-off-by: Babis Chalios <babis@voltanet.io>
Signed-off-by: Pat Ruddy Chalios <pat@voltanet.io>
2021-01-11 14:36:40 +00:00
Sebastien Merle
f7f6a796e8 pathd: Skip SR-TE topotests if pathd has been disabled
* If pathd binary is not found, skip the SR-TE topotests.
 * Fix some compilation warnings when pathd is not built.

Signed-off-by: Sebastien Merle <sebastien@netdef.org>
2021-01-11 12:52:15 +01:00
Adriano Marto Reis
733367c04e tests: tests for bgpd listing on multiple addresses
* Added a new topotest to test bgpd listening on multiple addresses.
* Updated the existing bgpd tests according to the parameter added to
bgp_master_init.

Signed-off-by: "Adriano Marto Reis" <adrianomarto@gmail.com>
2021-01-11 08:33:52 +00:00
Donald Sharp
7df0e6bb3b
Merge pull request #7756 from pjdruddy/bgplu-fixes
Bgplu fixes
2021-01-09 15:48:22 -05:00
Donald Sharp
537e7e9241 tests: Wait for bgp convergence *after* we re-add the interfaces
In test_bgp_mutli_vrf_topo2.py it's clear that we remove then
re-add the vrf interfaces.  Then the test was immediately
checking to ensure that the routes were available.

BGP needs time to reconverge.  Let's ensure that first.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-08 20:58:04 -05:00
Renato Westphal
ef8e91d4a2 tests: add IS-IS RLFA topotest
Add new RLFA topotest that tests all RLFA configuration knobs and
how isisd and ldpd react to various configuration changes that can
occur in the network.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2021-01-08 22:22:11 -03:00
Donald Sharp
662aa246aa tests: Fix gr_tests
The bgp_gr_functionality_topo1 test was shutting down an
interface on r2 and then trying to bring it up on r1.
Hijinx ensued.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-01-07 17:30:04 -05:00
Donatas Abraitis
acb92e3524
Merge pull request #7749 from wesleycoakley/bgpd-large-community-format-fix
bgpd: reject malformed large-communities
2021-01-07 10:33:59 +02:00
Donald Sharp
fe035acc87
Merge pull request #7820 from kuldeepkash/topojson_framework
tests: [topojson]Add/Enhance framework to support PIM automation
2021-01-06 08:59:34 -05:00
Wesley Coakley
c850908b9d bgpd: separate lcommunity validation from tokenizer
`lcommunity_gettoken` expects a space-delimeted list of 0 or more large
communities. `lcommunity_list_valid` can perform this check.
`lcommunity_list_valid` now validates large community lists more
accurately based on the following condition: Each quantity in a standard bgp
large community must:

1. Contain at least one digit
2. Fit within 4 octets
3. Contain only digits unless the lcommunity is "expanded"
4. Contain a valid regex if the lcommunity is "expanded"

Moreover we validate that each large community list contains exactly 3
such values separated by a single colon each.

One quirk of our validation which is worth documenting is:

```
bgp large-community-list standard test2 permit 1:c:3
bgp large-community-list expanded test1 permit 1:c:3
```

The first line will throw an error complaining about a "malformed community-list
value". The second line will be accepted because the each value is each treated as
a regex when matching large communities, it simply will never match anything so
it's rather useless.

Signed-off-by: Wesley Coakley <wcoakley@nvidia.com>
2021-01-06 07:18:20 -05:00
Donatas Abraitis
f32fc99078
Merge pull request #7815 from ckishimo/pytests
tests: fix typos and remove duplicate output
2021-01-06 09:08:35 +02:00
kuldeepkash
e58fdb55d6 tests: [topojson]Enhance lib/topojson.py to support PIM automation
1. Enhanced lib/topojson.py for creating topologies with switches and routers
2. Ran it through (black) for expected formatting

Signed-off-by: kuldeepkash <kashyapk@vmware.com>
2021-01-06 05:13:05 +00:00