1# SPDX-License-Identifier: BSD-2-Clause 2# 3# Copyright (c) 2026 Stormshield 4 5. $(atf_get_srcdir)/../../sys/common/vnet.subr 6 7atf_test_case "badfib" "cleanup" 8badfib_head() 9{ 10 atf_set descr "Test adding an interface to a non-existent FIB" 11 atf_set require.user root 12} 13badfib_body() 14{ 15 local epair 16 17 vnet_init 18 19 epair=$(vnet_mkepair) 20 atf_check -s exit:0 ifconfig ${epair}a fib 0 21 atf_check -s not-exit:0 -e not-empty \ 22 ifconfig ${epair}a fib $(sysctl -n net.fibs) 23} 24badfib_cleanup() 25{ 26 vnet_cleanup 27} 28 29atf_init_test_cases() 30{ 31 atf_add_test_case badfib 32} 33