selftests: Fix suppress test in fib_tests.sh
authorDavid Ahern <dsahern@gmail.com>
Tue, 21 Apr 2020 14:47:24 +0000 (08:47 -0600)
committerDavid S. Miller <davem@davemloft.net>
Wed, 22 Apr 2020 20:02:52 +0000 (13:02 -0700)
commit2c1dd4c110627c2a4f006643f074119205cfcff4
treed9080b0540fcb57f36e6f2143badd4f0e52758e6
parentd5812a86271e0a58cc5d5ec000514031f21fdaa2
selftests: Fix suppress test in fib_tests.sh

fib_tests is spewing errors:
    ...
    Cannot open network namespace "ns1": No such file or directory
    Cannot open network namespace "ns1": No such file or directory
    Cannot open network namespace "ns1": No such file or directory
    Cannot open network namespace "ns1": No such file or directory
    ping: connect: Network is unreachable
    Cannot open network namespace "ns1": No such file or directory
    Cannot open network namespace "ns1": No such file or directory
    ...

Each test entry in fib_tests is supposed to do its own setup and
cleanup. Right now the $IP commands in fib_suppress_test are
failing because there is no ns1. Add the setup/cleanup and logging
expected for each test.

Fixes: ca7a03c41753 ("ipv6: do not free rt if FIB_LOOKUP_NOREF is set on suppress rule")
Signed-off-by: David Ahern <dsahern@gmail.com>
Cc: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/fib_tests.sh