diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2021-05-20 09:00:46 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-05-20 09:00:46 -0400 |
| commit | 21967e4e820b51a9a3f35efd0794b9601d182569 (patch) | |
| tree | 0e92be2873c40f5444817942cbf064ed2362ca7b /tests | |
| parent | 91895b15a9a11f2b5d156f2ccf904f82c385b9cd (diff) | |
| parent | 5cfffcdd8dc6dfac0f0ffa444dcbcebaa8d7d58f (diff) | |
Merge pull request #8628 from idryzhov/isis-vrf-redist
isisd: fix redistribution in vrf
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/isisd/test_isis_spf.c | 6 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r1/r1_route.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r1/r1_route6.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r1/r1_topology.json | 6 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r2/r2_route.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r2/r2_route6.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r2/r2_topology.json | 6 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r3/r3_route.json | 6 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r3/r3_route6.json | 4 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r3/r3_topology.json | 12 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r4/r4_route.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r4/r4_route6.json | 4 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r4/r4_topology.json | 12 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r5/r5_route.json | 2 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r5/r5_route6.json | 4 | ||||
| -rw-r--r-- | tests/topotests/isis_topo1_vrf/r5/r5_topology.json | 12 |
16 files changed, 40 insertions, 44 deletions
diff --git a/tests/isisd/test_isis_spf.c b/tests/isisd/test_isis_spf.c index 915f849aec..b89a5a008e 100644 --- a/tests/isisd/test_isis_spf.c +++ b/tests/isisd/test_isis_spf.c @@ -51,8 +51,6 @@ enum test_type { #define F_LEVEL1_ONLY 0x08 #define F_LEVEL2_ONLY 0x10 -static struct isis *isis; - static void test_run_spf(struct vty *vty, const struct isis_topology *topology, const struct isis_test_node *root, struct isis_area *area, struct lspdb_head *lspdb, @@ -257,8 +255,8 @@ static int test_run(struct vty *vty, const struct isis_topology *topology, uint8_t fail_id[ISIS_SYS_ID_LEN] = {}; /* Init topology. */ - memcpy(isis->sysid, root->sysid, sizeof(isis->sysid)); area = isis_area_create("1", NULL); + memcpy(area->isis->sysid, root->sysid, sizeof(area->isis->sysid)); area->is_type = IS_LEVEL_1_AND_2; area->srdb.enabled = true; if (test_topology_load(topology, area, area->lspdb) != 0) { @@ -470,7 +468,6 @@ static void vty_do_exit(int isexit) { printf("\nend.\n"); - isis_finish(isis); cmd_terminate(); vty_terminate(); yang_terminate(); @@ -555,7 +552,6 @@ int main(int argc, char **argv) /* IS-IS inits. */ yang_module_load("frr-isisd"); - isis = isis_new(VRF_DEFAULT_NAME); SET_FLAG(im->options, F_ISIS_UNIT_TEST); debug_spf_events |= DEBUG_SPF_EVENTS; debug_lfa |= DEBUG_LFA; diff --git a/tests/topotests/isis_topo1_vrf/r1/r1_route.json b/tests/topotests/isis_topo1_vrf/r1/r1_route.json index f0a3593a4c..8359baadaf 100644 --- a/tests/topotests/isis_topo1_vrf/r1/r1_route.json +++ b/tests/topotests/isis_topo1_vrf/r1/r1_route.json @@ -2,7 +2,7 @@ "10.0.10.0/24": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r1/r1_route6.json b/tests/topotests/isis_topo1_vrf/r1/r1_route6.json index 888b9e2c42..74961262b4 100644 --- a/tests/topotests/isis_topo1_vrf/r1/r1_route6.json +++ b/tests/topotests/isis_topo1_vrf/r1/r1_route6.json @@ -18,7 +18,7 @@ "2001:db8:2:1::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r1/r1_topology.json b/tests/topotests/isis_topo1_vrf/r1/r1_topology.json index 1a6fe6d5c6..666fa52b19 100644 --- a/tests/topotests/isis_topo1_vrf/r1/r1_topology.json +++ b/tests/topotests/isis_topo1_vrf/r1/r1_topology.json @@ -33,7 +33,7 @@ }, { "interface": "r1-eth0", - "metric": "20", + "metric": "10", "next-hop": "r3", "parent": "r3(4)", "type": "IP TE", @@ -41,7 +41,7 @@ }, { "interface": "r1-eth0", - "metric": "20", + "metric": "10", "next-hop": "r3", "parent": "r3(4)", "type": "IP TE", @@ -67,8 +67,8 @@ "vertex": "r3" }, { + "metric": "10", "interface": "r1-eth0", - "metric": "20", "next-hop": "r3", "parent": "r3(4)", "type": "IP6 internal", diff --git a/tests/topotests/isis_topo1_vrf/r2/r2_route.json b/tests/topotests/isis_topo1_vrf/r2/r2_route.json index a26cdfad8e..e2eee112b3 100644 --- a/tests/topotests/isis_topo1_vrf/r2/r2_route.json +++ b/tests/topotests/isis_topo1_vrf/r2/r2_route.json @@ -2,7 +2,7 @@ "10.0.11.0/24": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r2/r2_route6.json b/tests/topotests/isis_topo1_vrf/r2/r2_route6.json index b01789b8d9..21b953d0f7 100644 --- a/tests/topotests/isis_topo1_vrf/r2/r2_route6.json +++ b/tests/topotests/isis_topo1_vrf/r2/r2_route6.json @@ -18,7 +18,7 @@ "2001:db8:2:2::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r2/r2_topology.json b/tests/topotests/isis_topo1_vrf/r2/r2_topology.json index a77f7977f9..c26ad1ee37 100644 --- a/tests/topotests/isis_topo1_vrf/r2/r2_topology.json +++ b/tests/topotests/isis_topo1_vrf/r2/r2_topology.json @@ -33,7 +33,7 @@ }, { "interface": "r2-eth0", - "metric": "20", + "metric": "10", "next-hop": "r4", "parent": "r4(4)", "type": "IP TE", @@ -41,7 +41,7 @@ }, { "interface": "r2-eth0", - "metric": "20", + "metric": "10", "next-hop": "r4", "parent": "r4(4)", "type": "IP TE", @@ -67,8 +67,8 @@ "vertex": "r4" }, { + "metric": "10", "interface": "r2-eth0", - "metric": "20", "next-hop": "r4", "parent": "r4(4)", "type": "IP6 internal", diff --git a/tests/topotests/isis_topo1_vrf/r3/r3_route.json b/tests/topotests/isis_topo1_vrf/r3/r3_route.json index 9717df5c1a..33ad90cda1 100644 --- a/tests/topotests/isis_topo1_vrf/r3/r3_route.json +++ b/tests/topotests/isis_topo1_vrf/r3/r3_route.json @@ -2,7 +2,7 @@ "10.0.10.0/24": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "afi": "ipv4", @@ -32,7 +32,7 @@ "10.0.11.0/24": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, @@ -67,7 +67,7 @@ "10.0.21.0/24": [ { "distance": 115, - "metric": 30, + "metric": 20, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r3/r3_route6.json b/tests/topotests/isis_topo1_vrf/r3/r3_route6.json index 31a1e4620f..519fe4968a 100644 --- a/tests/topotests/isis_topo1_vrf/r3/r3_route6.json +++ b/tests/topotests/isis_topo1_vrf/r3/r3_route6.json @@ -18,7 +18,7 @@ "2001:db8:1:2::/64": [ { "distance": 115, - "metric": 30, + "metric": 20, "nexthops": [ { "active": true, @@ -52,7 +52,7 @@ "2001:db8:2:2::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r3/r3_topology.json b/tests/topotests/isis_topo1_vrf/r3/r3_topology.json index 1e5d331965..34892d4a3a 100644 --- a/tests/topotests/isis_topo1_vrf/r3/r3_topology.json +++ b/tests/topotests/isis_topo1_vrf/r3/r3_topology.json @@ -21,7 +21,7 @@ }, { "interface": "r3-eth1", - "metric": "20", + "metric": "10", "next-hop": "r5", "parent": "r5(4)", "type": "IP TE", @@ -29,7 +29,7 @@ }, { "interface": "r3-eth1", - "metric": "20", + "metric": "10", "next-hop": "r5", "parent": "r5(4)", "type": "IP TE", @@ -37,7 +37,7 @@ }, { "interface": "r3-eth1", - "metric": "30", + "metric": "20", "next-hop": "r5", "parent": "r4(4)", "type": "IP TE", @@ -63,16 +63,16 @@ "vertex": "r5" }, { + "metric": "10", "interface": "r3-eth1", - "metric": "20", "next-hop": "r5", "parent": "r5(4)", "type": "IP6 internal", "vertex": "2001:db8:2:2::/64" }, { + "metric": "20", "interface": "r3-eth1", - "metric": "30", "next-hop": "r5", "parent": "r4(4)", "type": "IP6 internal", @@ -101,7 +101,7 @@ }, { "interface": "r3-eth0", - "metric": "20", + "metric": "10", "next-hop": "r3", "parent": "r3(4)", "type": "IP TE", diff --git a/tests/topotests/isis_topo1_vrf/r4/r4_route.json b/tests/topotests/isis_topo1_vrf/r4/r4_route.json index 6cb79b0301..6fb3bd99d1 100644 --- a/tests/topotests/isis_topo1_vrf/r4/r4_route.json +++ b/tests/topotests/isis_topo1_vrf/r4/r4_route.json @@ -1,7 +1,7 @@ { "10.0.10.0/24": [ { - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r4/r4_route6.json b/tests/topotests/isis_topo1_vrf/r4/r4_route6.json index 88a91749c2..702a83fb72 100644 --- a/tests/topotests/isis_topo1_vrf/r4/r4_route6.json +++ b/tests/topotests/isis_topo1_vrf/r4/r4_route6.json @@ -2,7 +2,7 @@ "2001:db8:1:1::/64": [ { "distance": 115, - "metric": 30, + "metric": 20, "nexthops": [ { "active": true, @@ -36,7 +36,7 @@ "2001:db8:2:1::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r4/r4_topology.json b/tests/topotests/isis_topo1_vrf/r4/r4_topology.json index 34f5ac9ca4..d40008aa30 100644 --- a/tests/topotests/isis_topo1_vrf/r4/r4_topology.json +++ b/tests/topotests/isis_topo1_vrf/r4/r4_topology.json @@ -21,7 +21,7 @@ }, { "interface": "r4-eth1", - "metric": "20", + "metric": "10", "next-hop": "r5", "parent": "r5(4)", "type": "IP TE", @@ -29,7 +29,7 @@ }, { "interface": "r4-eth1", - "metric": "20", + "metric": "10", "next-hop": "r5", "parent": "r5(4)", "type": "IP TE", @@ -37,7 +37,7 @@ }, { "interface": "r4-eth1", - "metric": "30", + "metric": "20", "next-hop": "r5", "parent": "r3(4)", "type": "IP TE", @@ -63,16 +63,16 @@ "vertex": "r5" }, { + "metric": "10", "interface": "r4-eth1", - "metric": "20", "next-hop": "r5", "parent": "r5(4)", "type": "IP6 internal", "vertex": "2001:db8:2:1::/64" }, { + "metric": "20", "interface": "r4-eth1", - "metric": "30", "next-hop": "r5", "parent": "r3(4)", "type": "IP6 internal", @@ -101,7 +101,7 @@ }, { "interface": "r4-eth0", - "metric": "20", + "metric": "10", "next-hop": "r2", "parent": "r2(4)", "type": "IP TE", diff --git a/tests/topotests/isis_topo1_vrf/r5/r5_route.json b/tests/topotests/isis_topo1_vrf/r5/r5_route.json index 5efa36bce6..a254b6fdd5 100644 --- a/tests/topotests/isis_topo1_vrf/r5/r5_route.json +++ b/tests/topotests/isis_topo1_vrf/r5/r5_route.json @@ -2,7 +2,7 @@ "10.0.10.0/24": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "afi": "ipv4", diff --git a/tests/topotests/isis_topo1_vrf/r5/r5_route6.json b/tests/topotests/isis_topo1_vrf/r5/r5_route6.json index 5e8f6364af..06fc78f703 100644 --- a/tests/topotests/isis_topo1_vrf/r5/r5_route6.json +++ b/tests/topotests/isis_topo1_vrf/r5/r5_route6.json @@ -2,7 +2,7 @@ "2001:db8:1:1::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, @@ -20,7 +20,7 @@ "2001:db8:1:2::/64": [ { "distance": 115, - "metric": 20, + "metric": 10, "nexthops": [ { "active": true, diff --git a/tests/topotests/isis_topo1_vrf/r5/r5_topology.json b/tests/topotests/isis_topo1_vrf/r5/r5_topology.json index ace56536e9..2a088cae30 100644 --- a/tests/topotests/isis_topo1_vrf/r5/r5_topology.json +++ b/tests/topotests/isis_topo1_vrf/r5/r5_topology.json @@ -35,7 +35,7 @@ }, { "interface": "r5-eth0", - "metric": "20", + "metric": "10", "next-hop": "r3", "parent": "r3(4)", "type": "IP TE", @@ -43,7 +43,7 @@ }, { "interface": "r5-eth0", - "metric": "20", + "metric": "10", "next-hop": "r3", "parent": "r3(4)", "type": "IP TE", @@ -51,7 +51,7 @@ }, { "interface": "r5-eth1", - "metric": "20", + "metric": "10", "next-hop": "r4", "parent": "r4(4)", "type": "IP TE", @@ -59,7 +59,7 @@ }, { "interface": "r5-eth1", - "metric": "20", + "metric": "10", "next-hop": "r4", "parent": "r4(4)", "type": "IP TE", @@ -99,16 +99,16 @@ "vertex": "r4" }, { + "metric": "10", "interface": "r5-eth0", - "metric": "20", "next-hop": "r3", "parent": "r3(4)", "type": "IP6 internal", "vertex": "2001:db8:1:1::/64" }, { + "metric": "10", "interface": "r5-eth1", - "metric": "20", "next-hop": "r4", "parent": "r4(4)", "type": "IP6 internal", |
