testsuite: make alltests fixes
Subsystems (2)
v2 cover testsuite: make alltests fixes
Hi,
here are simply fixes to restore 'make alltests'.
Currently it does not run.
Kind regards,
Petr
Petr Vorel (3):
testsuite: Fix missing generate_nlmsg
testsuite: Generate generate_nlmsg when needed
testsuite: Warn about empty $(IPVERS)
testsuite/Makefile | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-)
Signature · 1 line
2.19.0.rc2
PATCH v2 1/3 testsuite: Fix missing generate_nlmsg
Commit ad23e152 caused generate_nlmsg to be always missing:
$ make alltests make: ./tools/generate_nlmsg: Command not found
Create testclean: to remove only results directory.
--- testsuite/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
testsuite/Makefile +6 -5
@@ -30,7 +30,6 @@ configure: compile: configure echo "Entering iproute2" && cd iproute2 && $(MAKE) && cd ..; - $(MAKE) -C tools listtests: @for t in $(TESTS); do \
@@ -39,9 +38,11 @@ listtests: alltests: $(TESTS) -clean: +testclean: @echo "Removing $(RESULTS_DIR) dir ..." @rm -rf $(RESULTS_DIR) + +clean: testclean @rm -f iproute2/iproute2-this @rm -f tests/ip/link/dev_wo_vf_rate.nl $(MAKE) -C tools clean
@@ -49,18 +50,18 @@ clean: distclean: clean echo "Entering iproute2" && cd iproute2 && $(MAKE) distclean && cd ..; -$(TESTS): clean +$(TESTS): testclean ifeq (,$(HAVE_UNSHARED_UTIL)) $(error Please install util-linux tools to run tests in separated network namespace) endif @./tools/generate_nlmsg @mkdir -p $(RESULTS_DIR) - + @for d in $(TESTS_DIR); do \ mkdir -p $(RESULTS_DIR)/$$d; \ done - + @if [ "$(KCPATH)" = "/proc/config.gz" ]; then \ gunzip -c $(KCPATH) >$(KENVFN); \ elif [ "$(KCPATH)" != "" ]; then \
Signature · 1 line
2.19.0.rc2
PATCH v2 2/3 testsuite: Generate generate_nlmsg when needed
In reply to Petr VorelCommit 886f2c43 added generate_nlmsg.c. Running alltests target, which uses the binary required to run 'make -C tools' before.
--- testsuite/Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
testsuite/Makefile +5 -2
@@ -28,7 +28,7 @@ endif configure: echo "Entering iproute2" && cd iproute2 && $(MAKE) configure && cd ..; -compile: configure +compile: configure generate_nlmsg echo "Entering iproute2" && cd iproute2 && $(MAKE) && cd ..; listtests:
@@ -36,7 +36,10 @@ listtests: echo "$$t"; \ done -alltests: $(TESTS) +generate_nlmsg: + $(MAKE) -C tools + +alltests: generate_nlmsg $(TESTS) testclean: @echo "Removing $(RESULTS_DIR) dir ..."
Signature · 1 line
2.19.0.rc2
PATCH v2 3/3 testsuite: Warn about empty $(IPVERS)
In reply to Petr Vorelalltests target requires having symlink created by configure target (default target). Without that there is no test being run.
--- testsuite/Makefile | 3 +++ 1 file changed, 3 insertions(+)
testsuite/Makefile +3 -0
@@ -54,6 +54,9 @@ distclean: clean echo "Entering iproute2" && cd iproute2 && $(MAKE) distclean && cd ..; $(TESTS): testclean +ifeq (,$(IPVERS)) + $(error Please run make first) +endif ifeq (,$(HAVE_UNSHARED_UTIL)) $(error Please install util-linux tools to run tests in separated network namespace) endif
Signature · 1 line
2.19.0.rc2
Hi Petr,
Quoted 2 lines · Petr Vorel
here are simply fixes to restore 'make alltests'.
Currently it does not run.
Yeah, that testsuite definitely deserves some love.
Just one nit: The one-line summary in Fixes: tags should be enclosed in quotes and parens, e.g.:
| Fixes: deadbeef ("foo bar")
Cheers, Phil
Quoted 8 lines · Petr Vorel
Hi,
here are simply fixes to restore 'make alltests'.
Currently it does not run.Kind regards,
Petr
Quoted 7 lines
Petr Vorel (3):
testsuite: Fix missinggenerate_nlmsg
testsuite: Generategenerate_nlmsgwhen needed
testsuite: Warn about empty $(IPVERS)testsuite/Makefile | 21 ++++++++++++++-------
1 file changed, 14 insertions(+), 7 deletions(-)
Signature · 2 lines
Kind regards, Luca Boccassi
Quoted 8 lines · On Thu, 20 Sep 2018 01:36:21 +0200 Petr Vorel <[email protected]> wrote:
Hi,
here are simply fixes to restore 'make alltests'.
Currently it does not run.Kind regards,
Petr
Quoted 8 lines
Petr Vorel (3):
testsuite: Fix missinggenerate_nlmsg
testsuite: Generategenerate_nlmsgwhen needed
testsuite: Warn about empty $(IPVERS)testsuite/Makefile | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-)
Applied, it would be good to have 'make tests' at the top level.