[banshee] tests: bail early if nunit-console is not found (bgo#722565)



commit c56e89b37f4b9173dab5d8086dad5b1f7eac525b
Author: Andrés G. Aragoneses <knocte gmail com>
Date:   Sun Jan 19 22:08:37 2014 +0100

    tests: bail early if nunit-console is not found (bgo#722565)
    
    It's not worth checking for this at configure time because
    one can build Banshee fine when having nunit libraries but
    not the runner (i.e.: in a Debian-based distro, having the
    package "libnunit-cil-dev" installed, but not the one
    named "nunit-console").
    
    But we need to check before running the tests, otherwise
    the user may get many errors (as many as the number of
    test assemblies we have), instead of just one, making it
    very clear what is missing.

 tests/Makefile.am |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 957eb60..38f5bae 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -33,6 +33,10 @@ ENV_OPTIONS = TZ=America/Chicago LC_ALL=it_IT LANG=it_IT
 MONO_OPTIONS = MONO_ENV_OPTIONS=--debug
 NUNIT_CONSOLE = $$(echo $$(which nunit-console2 || which nunit-console))
 RUNNER = \
+       if [[ "x$(NUNIT_CONSOLE)" = "x" ]]; then \
+               echo "NUnit runner not found; please install nunit-console or nunit-console2"; \
+               exit 1; \
+       fi; \
        GLOBAL_EXIT_CODE=0; \
        for asm in $${TEST_ASSEMBLIES}; do \
                echo -e "\033[1mRunning tests on $${asm}...\033[0m"; \


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]