Skip to content

Commit

Permalink
selftests: bonding: Add net/forwarding/lib.sh to TEST_INCLUDES
Browse files Browse the repository at this point in the history
In order to avoid duplicated files when both the bonding and forwarding
tests are exported together, add net/forwarding/lib.sh to TEST_INCLUDES and
include it via its relative path.

Reviewed-by: Petr Machata <petrm@nvidia.com>
Tested-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Hangbin Liu <liuhangbin@gmail.com>
Signed-off-by: Benjamin Poirier <bpoirier@nvidia.com>
Reviewed-by: Jay Vosburgh <jay.vosburgh@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Benjamin Poirier authored and David S. Miller committed Jan 31, 2024
1 parent 2a0683b commit 6500780
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 8 deletions.
6 changes: 4 additions & 2 deletions tools/testing/selftests/drivers/net/bonding/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ TEST_PROGS := \
TEST_FILES := \
lag_lib.sh \
bond_topo_2d1c.sh \
bond_topo_3d1c.sh \
net_forwarding_lib.sh
bond_topo_3d1c.sh

TEST_INCLUDES := \
../../../net/forwarding/lib.sh

include ../../../lib.mk
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ALL_TESTS="
REQUIRE_MZ=no
NUM_NETIFS=0
lib_dir=$(dirname "$0")
source "$lib_dir"/net_forwarding_lib.sh
source "$lib_dir"/../../../net/forwarding/lib.sh

bond_check_flags()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
REQUIRE_MZ=no
NUM_NETIFS=0
lib_dir=$(dirname "$0")
source ${lib_dir}/net_forwarding_lib.sh
source "$lib_dir"/../../../net/forwarding/lib.sh

s_ns="s-$(mktemp -u XXXXXX)"
c_ns="c-$(mktemp -u XXXXXX)"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ALL_TESTS="
REQUIRE_MZ=no
NUM_NETIFS=0
lib_dir=$(dirname "$0")
source "$lib_dir"/net_forwarding_lib.sh
source "$lib_dir"/../../../net/forwarding/lib.sh

source "$lib_dir"/lag_lib.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ REQUIRE_MZ=no
REQUIRE_JQ=no
NUM_NETIFS=0
lib_dir=$(dirname "$0")
source "$lib_dir"/net_forwarding_lib.sh
source "$lib_dir"/../../../net/forwarding/lib.sh
source "$lib_dir"/lag_lib.sh

cleanup()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ REQUIRE_MZ=no
REQUIRE_JQ=no
NUM_NETIFS=0
lib_dir=$(dirname "$0")
source "$lib_dir"/net_forwarding_lib.sh
source "$lib_dir"/../../../net/forwarding/lib.sh
source "$lib_dir"/lag_lib.sh

cleanup()
Expand Down

This file was deleted.

0 comments on commit 6500780

Please sign in to comment.