diff mbox

[PULL,v4,02/12] tests: lm32: new rule for single test cases

Message ID 1390246471-25167-3-git-send-email-michael@walle.cc
State New
Headers show

Commit Message

Michael Walle Jan. 20, 2014, 7:34 p.m. UTC
Introduce new target "check_%" to run indiviudal test caes, eg.
  make check_mmu

Signed-off-by: Michael Walle <michael@walle.cc>
---
 tests/tcg/lm32/Makefile |    3 +++
 1 file changed, 3 insertions(+)

Comments

Peter Maydell Feb. 1, 2014, 5:45 p.m. UTC | #1
On 20 January 2014 19:34, Michael Walle <michael@walle.cc> wrote:
> Introduce new target "check_%" to run indiviudal test caes, eg.
>   make check_mmu

"individual". Otherwise
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

>
> Signed-off-by: Michael Walle <michael@walle.cc>
> ---
>  tests/tcg/lm32/Makefile |    3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/tests/tcg/lm32/Makefile b/tests/tcg/lm32/Makefile
> index 9a00ef7..19e0664 100644
> --- a/tests/tcg/lm32/Makefile
> +++ b/tests/tcg/lm32/Makefile
> @@ -101,5 +101,8 @@ check: $(CRT) $(SYS) $(TESTCASES)
>                 $(SIM) $(SIMFLAGS) ./$$case; \
>         done
>
> +check_%: test_%.tst $(CRT) $(SYS)
> +       $(SIM) $(SIMFLAGS) $<
> +
>  clean:
>         $(RM) -fr $(TESTCASES) $(CRT)


You could reimplement the 'check' target to just
depend on $(TESTCASES:test_%.tst=check_%)
rather than doing an explicit loop if you like, but that's optional.

thanks
-- PMM
diff mbox

Patch

diff --git a/tests/tcg/lm32/Makefile b/tests/tcg/lm32/Makefile
index 9a00ef7..19e0664 100644
--- a/tests/tcg/lm32/Makefile
+++ b/tests/tcg/lm32/Makefile
@@ -101,5 +101,8 @@  check: $(CRT) $(SYS) $(TESTCASES)
 		$(SIM) $(SIMFLAGS) ./$$case; \
 	done
 
+check_%: test_%.tst $(CRT) $(SYS)
+	$(SIM) $(SIMFLAGS) $<
+
 clean:
 	$(RM) -fr $(TESTCASES) $(CRT)