From 32b7dda832c8cfb9965e70d34cd98aa112a9f752 Mon Sep 17 00:00:00 2001 From: Maximilian Wilhelm Date: Sat, 5 Sep 2020 00:28:12 +0200 Subject: [PATCH] tests: Add test for dummy link creation. Signed-off-by: Maximilian Wilhelm --- tests/linux/link_test | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/linux/link_test b/tests/linux/link_test index c4389f4..db3e787 100755 --- a/tests/linux/link_test +++ b/tests/linux/link_test @@ -13,7 +13,8 @@ tests_init \ vlan_guessed_pre_up \ vlan_guessed_post_down \ vlan_explicit_depend \ - vlan_guessed_depend + vlan_guessed_depend \ + dummy_pre_up up_body() { export IFACE=lo PHASE=up MOCK=echo @@ -77,3 +78,9 @@ vlan_guessed_depend_body() { atf_check -s exit:0 -o match:'eth0' \ ${EXECUTOR} } + +dummy_pre_up_body() { + export IFACE=yolo IF_LINK_TYPE=dummy PHASE=pre-up MOCK=echo + atf_check -s exit:0 -o match:'ip link add yolo type dummy' \ + ${EXECUTOR} +}