From b169f222bf348663c0108d6641ccb17560bd8cd2 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Tue, 16 Dec 2014 23:35:31 +0100 Subject: [PATCH] platform/tests: for route tests, add test routes with a different metric If we have NM running, adding a route with metric 20 might conflict and cause NM to remove the route. Choose a different (higher) metric that is less likely to cause a conflict. --- src/platform/tests/test-route.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/platform/tests/test-route.c b/src/platform/tests/test-route.c index ea238f5d6c..2c70b412bb 100644 --- a/src/platform/tests/test-route.c +++ b/src/platform/tests/test-route.c @@ -61,7 +61,8 @@ test_ip4_route (void) in_addr_t network; int plen = 24; in_addr_t gateway; - int metric = 20; + /* Choose a high metric so that we hopefully don't conflict. */ + int metric = 22986; int mss = 1000; inet_pton (AF_INET, "192.0.3.0", &network); @@ -156,7 +157,8 @@ test_ip6_route (void) struct in6_addr network; int plen = 64; struct in6_addr gateway; - int metric = 20; + /* Choose a high metric so that we hopefully don't conflict. */ + int metric = 22987; int mss = 1000; inet_pton (AF_INET6, "2001:db8:a:b:0:0:0:0", &network);