Compilation: restore remove check-recursive warning message 81/6681/3
Clément DAVID [Mon, 12 Mar 2012 13:22:32 +0000 (14:22 +0100)]
 * `make check` launch per module Java and test_run("module")
 * `make check-TESTS` launch tests only (automake Simple Tests framework)

Change-Id: I870d63116adc16441f56e8d0b3382c25d651e388

84 files changed:
scilab/Makefile.am
scilab/Makefile.in
scilab/Makefile.incl.am
scilab/libs/MALLOC/Makefile.in
scilab/libs/doublylinkedlist/Makefile.in
scilab/libs/dynamiclibrary/Makefile.in
scilab/libs/hashtable/Makefile.in
scilab/libs/libst/Makefile.in
scilab/modules/action_binding/Makefile.in
scilab/modules/api_scilab/Makefile.in
scilab/modules/arnoldi/Makefile.in
scilab/modules/atoms/Makefile.in
scilab/modules/boolean/Makefile.in
scilab/modules/cacsd/Makefile.in
scilab/modules/call_scilab/Makefile.in
scilab/modules/commons/Makefile.in
scilab/modules/compatibility_functions/Makefile.in
scilab/modules/completion/Makefile.in
scilab/modules/console/Makefile.in
scilab/modules/core/Makefile.in
scilab/modules/data_structures/Makefile.in
scilab/modules/demo_tools/Makefile.in
scilab/modules/development_tools/Makefile.in
scilab/modules/development_tools/tests/unit_tests/test_run_level_1.tst [new file with mode: 0644]
scilab/modules/development_tools/tests/unit_tests/test_run_level_2.tst [new file with mode: 0644]
scilab/modules/differential_equations/Makefile.in
scilab/modules/double/Makefile.in
scilab/modules/dynamic_link/Makefile.in
scilab/modules/elementary_functions/Makefile.in
scilab/modules/fftw/Makefile.in
scilab/modules/fileio/Makefile.in
scilab/modules/functions/Makefile.in
scilab/modules/genetic_algorithms/Makefile.in
scilab/modules/graph/Makefile.in
scilab/modules/graphic_export/Makefile.in
scilab/modules/graphics/Makefile.in
scilab/modules/gui/Makefile.in
scilab/modules/hdf5/Makefile.in
scilab/modules/helptools/Makefile.in
scilab/modules/history_browser/Makefile.in
scilab/modules/history_manager/Makefile.in
scilab/modules/integer/Makefile.in
scilab/modules/interpolation/Makefile.in
scilab/modules/intersci/Makefile.in
scilab/modules/io/Makefile.in
scilab/modules/javasci/Makefile.in
scilab/modules/jvm/Makefile.in
scilab/modules/linear_algebra/Makefile.in
scilab/modules/localization/Makefile.in
scilab/modules/m2sci/Makefile.in
scilab/modules/matio/Makefile.in
scilab/modules/mexlib/Makefile.in
scilab/modules/modules_manager/Makefile.in
scilab/modules/optimization/Makefile.in
scilab/modules/output_stream/Makefile.in
scilab/modules/overloading/Makefile.in
scilab/modules/parallel/Makefile.in
scilab/modules/parameters/Makefile.in
scilab/modules/polynomials/Makefile.in
scilab/modules/prebuildjava/Makefile.in
scilab/modules/prebuildjava/build.xml
scilab/modules/preferences/Makefile.in
scilab/modules/randlib/Makefile.in
scilab/modules/renderer/Makefile.in
scilab/modules/scicos/Makefile.in
scilab/modules/scicos_blocks/Makefile.in
scilab/modules/scinotes/Makefile.in
scilab/modules/signal_processing/Makefile.in
scilab/modules/simulated_annealing/Makefile.in
scilab/modules/sound/Makefile.in
scilab/modules/sparse/Makefile.in
scilab/modules/special_functions/Makefile.in
scilab/modules/spreadsheet/Makefile.in
scilab/modules/statistics/Makefile.in
scilab/modules/string/Makefile.in
scilab/modules/symbolic/Makefile.in
scilab/modules/tclsci/Makefile.in
scilab/modules/time/Makefile.in
scilab/modules/types/Makefile.in
scilab/modules/ui_data/Makefile.in
scilab/modules/umfpack/Makefile.in
scilab/modules/windows_tools/Makefile.in
scilab/modules/xcos/Makefile.in
scilab/modules/xml/Makefile.in

index 2c15b81..c0295cf 100644 (file)
@@ -91,6 +91,10 @@ if COMPILATION_TESTS
 TARGETS_ALL+=check-java
 endif
 
+# check is performed with scilab
+TESTS_ENVIRONMENT = LANG=C $(top_builddir)/bin/scilab -nwni -nb -noatomsautoload -f
+TESTS = $(top_srcdir)/modules/development_tools/tests/unit_tests/test_run_level_1.tst
+
 all-local: $(TARGETS_ALL)
 
 rootdir=$(pkgdatadir)/etc/
@@ -194,18 +198,6 @@ check-help:$(top_builddir)/scilab-cli-bin $(top_builddir)/bin/scilab-cli
                echo "Cannot find Scilab binary"; \
        fi
 
-check-recursive: check-local
-       @echo "Check resursive disabled"
-check-local:
-       @if test -x $(top_builddir)/scilab-bin; then \
-               COMMAND="try test_run_level(1);catch exit(-1);end;exit(0)";\
-               export LANG=C;\
-               echo "LANG=C $(top_builddir)/bin/scilab-cli -nb -noatomsautoload -e \"$$COMMAND\""; \
-               time $(top_builddir)/bin/scilab-cli -nb -noatomsautoload -e "$$COMMAND"; \
-       else \
-               echo "Cannot find Scilab binary"; \
-       fi
-
 code-coverage:
 if CODE_COVERAGE
        @if test ! -d $(top_builddir)/coverage/; then \
index 4190811..daed274 100644 (file)
@@ -297,6 +297,8 @@ AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
        distdir dist dist-all distcheck
 ETAGS = etags
 CTAGS = ctags
+am__tty_colors = \
+red=; grn=; lgn=; blu=; std=
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
@@ -620,6 +622,10 @@ scilab_cli_bin_LDADD = $(COMMON_LIBS) $(top_builddir)/modules/libscilab-cli.la $
 @ENABLE_STATIC_TRUE@scilab_static_bin_SOURCES = $(scilab_bin_SOURCES)
 LANG_DOMAIN = scilab
 TARGETS_ALL = macros $(am__append_4) $(am__append_5)
+
+# check is performed with scilab
+TESTS_ENVIRONMENT = LANG=C $(top_builddir)/bin/scilab -nwni -nb -noatomsautoload -f
+TESTS = $(top_srcdir)/modules/development_tools/tests/unit_tests/test_run_level_1.tst
 rootdir = $(pkgdatadir)/etc/
 root_DATA = $(top_srcdir)/etc/scilab.start \
 $(top_srcdir)/etc/scilab.quit \
@@ -1305,6 +1311,99 @@ GTAGS:
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+check-TESTS: $(TESTS)
+       @failed=0; all=0; xfail=0; xpass=0; skip=0; \
+       srcdir=$(srcdir); export srcdir; \
+       list=' $(TESTS) '; \
+       $(am__tty_colors); \
+       if test -n "$$list"; then \
+         for tst in $$list; do \
+           if test -f ./$$tst; then dir=./; \
+           elif test -f $$tst; then dir=; \
+           else dir="$(srcdir)/"; fi; \
+           if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
+             all=`expr $$all + 1`; \
+             case " $(XFAIL_TESTS) " in \
+             *[\ \     ]$$tst[\ \      ]*) \
+               xpass=`expr $$xpass + 1`; \
+               failed=`expr $$failed + 1`; \
+               col=$$red; res=XPASS; \
+             ;; \
+             *) \
+               col=$$grn; res=PASS; \
+             ;; \
+             esac; \
+           elif test $$? -ne 77; then \
+             all=`expr $$all + 1`; \
+             case " $(XFAIL_TESTS) " in \
+             *[\ \     ]$$tst[\ \      ]*) \
+               xfail=`expr $$xfail + 1`; \
+               col=$$lgn; res=XFAIL; \
+             ;; \
+             *) \
+               failed=`expr $$failed + 1`; \
+               col=$$red; res=FAIL; \
+             ;; \
+             esac; \
+           else \
+             skip=`expr $$skip + 1`; \
+             col=$$blu; res=SKIP; \
+           fi; \
+           echo "$${col}$$res$${std}: $$tst"; \
+         done; \
+         if test "$$all" -eq 1; then \
+           tests="test"; \
+           All=""; \
+         else \
+           tests="tests"; \
+           All="All "; \
+         fi; \
+         if test "$$failed" -eq 0; then \
+           if test "$$xfail" -eq 0; then \
+             banner="$$All$$all $$tests passed"; \
+           else \
+             if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
+             banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
+           fi; \
+         else \
+           if test "$$xpass" -eq 0; then \
+             banner="$$failed of $$all $$tests failed"; \
+           else \
+             if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
+             banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
+           fi; \
+         fi; \
+         dashes="$$banner"; \
+         skipped=""; \
+         if test "$$skip" -ne 0; then \
+           if test "$$skip" -eq 1; then \
+             skipped="($$skip test was not run)"; \
+           else \
+             skipped="($$skip tests were not run)"; \
+           fi; \
+           test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
+             dashes="$$skipped"; \
+         fi; \
+         report=""; \
+         if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
+           report="Please report to $(PACKAGE_BUGREPORT)"; \
+           test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
+             dashes="$$report"; \
+         fi; \
+         dashes=`echo "$$dashes" | sed s/./=/g`; \
+         if test "$$failed" -eq 0; then \
+           col="$$grn"; \
+         else \
+           col="$$red"; \
+         fi; \
+         echo "$${col}$$dashes$${std}"; \
+         echo "$${col}$$banner$${std}"; \
+         test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
+         test -z "$$report" || echo "$${col}$$report$${std}"; \
+         echo "$${col}$$dashes$${std}"; \
+         test "$$failed" -eq 0; \
+       else :; fi
+
 distdir: $(DISTFILES)
        $(am__remove_distdir)
        test -d "$(distdir)" || mkdir "$(distdir)"
@@ -1498,7 +1597,7 @@ distcleancheck: distclean
               exit 1; } >&2
 check-am: all-am
        $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS)
-       $(MAKE) $(AM_MAKEFLAGS) check-local
+       $(MAKE) $(AM_MAKEFLAGS) check-TESTS
 check: check-recursive
 all-am: Makefile $(PROGRAMS) $(SCRIPTS) $(DATA) all-local
 installdirs: installdirs-recursive
@@ -1618,7 +1717,7 @@ uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS \
        ctags-recursive install-am install-strip tags-recursive
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-       all all-am all-local am--refresh check check-am check-local \
+       all all-am all-local am--refresh check check-TESTS check-am \
        clean clean-binPROGRAMS clean-checkPROGRAMS clean-generic \
        clean-libtool ctags ctags-recursive dist dist-all dist-bzip2 \
        dist-gzip dist-lzip dist-lzma dist-shar dist-tarZ dist-xz \
@@ -1710,18 +1809,6 @@ check-help:$(top_builddir)/scilab-cli-bin $(top_builddir)/bin/scilab-cli
                echo "Cannot find Scilab binary"; \
        fi
 
-check-recursive: check-local
-       @echo "Check resursive disabled"
-check-local:
-       @if test -x $(top_builddir)/scilab-bin; then \
-               COMMAND="try test_run_level(1);catch exit(-1);end;exit(0)";\
-               export LANG=C;\
-               echo "LANG=C $(top_builddir)/bin/scilab-cli -nb -noatomsautoload -e \"$$COMMAND\""; \
-               time $(top_builddir)/bin/scilab-cli -nb -noatomsautoload -e "$$COMMAND"; \
-       else \
-               echo "Cannot find Scilab binary"; \
-       fi
-
 code-coverage:
 @CODE_COVERAGE_TRUE@   @if test ! -d $(top_builddir)/coverage/; then \
 @CODE_COVERAGE_TRUE@           mkdir $(top_builddir)/coverage/; \
index a6e47c5..e1e6ede 100644 (file)
@@ -20,9 +20,9 @@ mydatadir=$(pkgdatadir)/modules/$(modulename)
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 
 # splint options
 SPLINT_OPTIONS=-weak -booltype BOOL
index 150c43b..5bf3f45 100644 (file)
@@ -834,9 +834,9 @@ uninstall-am: uninstall-libscimalloc_la_includeHEADERS \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 38fa917..48bf844 100644 (file)
@@ -817,9 +817,9 @@ uninstall-am: uninstall-libscidoublylinkedlist_la_includeHEADERS \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index b016443..1e90ce3 100644 (file)
@@ -819,9 +819,9 @@ uninstall-am: uninstall-libscidynamiclibrary_la_includeHEADERS \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 44c427a..43f52c2 100644 (file)
@@ -814,9 +814,9 @@ uninstall-am: uninstall-libscihashtable_la_includeHEADERS \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 37848bc..fe62d05 100644 (file)
@@ -778,9 +778,9 @@ uninstall-am: uninstall-pkglibLTLIBRARIES
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index e8a3e67..9afc251 100644 (file)
@@ -1051,9 +1051,9 @@ uninstall-am: uninstall-libsciaction_binding_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 4b60164..03abc39 100644 (file)
@@ -1018,9 +1018,9 @@ uninstall-am: uninstall-libsciapi_scilab_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index b12a687..7b5b838 100644 (file)
@@ -932,9 +932,9 @@ uninstall-am: uninstall-libsciarnoldi_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index cffe3d8..08ef4cd 100644 (file)
@@ -726,9 +726,9 @@ uninstall-am: uninstall-libsciatoms_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 0252b3e..96f35a1 100644 (file)
@@ -1000,9 +1000,9 @@ uninstall-am: uninstall-libsciboolean_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index f60a312..b1422b4 100644 (file)
@@ -1809,9 +1809,9 @@ uninstall-am: uninstall-libscicacsd_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 36640f4..79fac1d 100644 (file)
@@ -1003,9 +1003,9 @@ uninstall-am: uninstall-libscicall_scilab_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ebe8570..83b4698 100644 (file)
@@ -998,9 +998,9 @@ uninstall-am: uninstall-libscicommons_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 13ad113..aad0fc2 100644 (file)
@@ -687,9 +687,9 @@ uninstall-am: uninstall-libscicompatibility_functions_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index f883e73..bb12346 100644 (file)
@@ -1212,9 +1212,9 @@ uninstall-am: uninstall-libscicompletion_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 32c60f3..c283aa7 100644 (file)
@@ -1698,9 +1698,9 @@ uninstall-am: uninstall-libsciconsole_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index c5c0acf..c081cd1 100644 (file)
@@ -2886,9 +2886,9 @@ uninstall-am: uninstall-libscicore_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 94c0ab8..4800abf 100644 (file)
@@ -1174,9 +1174,9 @@ libdummy_data_structures_la-intl_e.lo: src/fortran/intl_e.f
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 15db035..c3b7154 100644 (file)
@@ -709,9 +709,9 @@ uninstall-am: uninstall-libdemo_tools_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index da19fb2..d60dfe7 100644 (file)
@@ -684,9 +684,9 @@ uninstall-am: uninstall-libdevelopment_tools_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
diff --git a/scilab/modules/development_tools/tests/unit_tests/test_run_level_1.tst b/scilab/modules/development_tools/tests/unit_tests/test_run_level_1.tst
new file mode 100644 (file)
index 0000000..5fb2154
--- /dev/null
@@ -0,0 +1,15 @@
+// =============================================================================
+// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+// Copyright (C) 2012 - Scilab Enterprises - Clement DAVID
+//
+//  This file is distributed under the same license as the Scilab package.
+// =============================================================================
+
+// Simple launcher for run level 1
+try
+    test_run_level(1);
+catch
+    exit(-1);
+end
+exit(0)
+
diff --git a/scilab/modules/development_tools/tests/unit_tests/test_run_level_2.tst b/scilab/modules/development_tools/tests/unit_tests/test_run_level_2.tst
new file mode 100644 (file)
index 0000000..48696cc
--- /dev/null
@@ -0,0 +1,15 @@
+// =============================================================================
+// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+// Copyright (C) 2012 - Scilab Enterprises - Clement DAVID
+//
+//  This file is distributed under the same license as the Scilab package.
+// =============================================================================
+
+// Simple launcher for run level 2
+try
+    test_run_level(2);
+catch
+    exit(-1);
+end
+exit(0)
+
index 722e24f..d3ece7b 100644 (file)
@@ -1552,9 +1552,9 @@ uninstall-am: uninstall-libscidifferential_equations_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 621ed9e..95446c4 100644 (file)
@@ -957,9 +957,9 @@ uninstall-am: uninstall-libscidouble_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d89f577..80273a7 100644 (file)
@@ -1143,9 +1143,9 @@ uninstall-am: uninstall-libscidynamic_link_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index e7874d7..3fab350 100644 (file)
@@ -2896,9 +2896,9 @@ libdummy_elementary_functions_la-icopy.lo: src/fortran/linpack/icopy.f
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index a71fb60..5962441 100644 (file)
@@ -1107,9 +1107,9 @@ uninstall-am: uninstall-libscifftw_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 2e55667..f9f636e 100644 (file)
@@ -1895,9 +1895,9 @@ uninstall-am: uninstall-libscifileio_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 8cdf9fd..1b10914 100644 (file)
@@ -1062,9 +1062,9 @@ uninstall-am: uninstall-libscifunctions_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 95d9160..5148547 100644 (file)
@@ -688,9 +688,9 @@ uninstall-am: uninstall-libgenetic_algorithms_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index b122185..22cca4f 100644 (file)
@@ -690,9 +690,9 @@ uninstall-am: uninstall-libscigraph_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 65e91ef..6ddd136 100644 (file)
@@ -1201,9 +1201,9 @@ uninstall-am: uninstall-libscigraphic_export_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d17ebe3..afd84d4 100644 (file)
@@ -4756,9 +4756,9 @@ uninstall-am: uninstall-libscigraphics_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 0e828b9..c2d991d 100644 (file)
@@ -2554,9 +2554,9 @@ uninstall-am: uninstall-libscigui_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 724921b..1d1bc9f 100644 (file)
@@ -1172,9 +1172,9 @@ uninstall-am: uninstall-libscihdf5_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ad31dab..c97c4fb 100644 (file)
@@ -1242,9 +1242,9 @@ uninstall-am: uninstall-libscihelptools_la_binDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 1166678..c5e020a 100644 (file)
@@ -1015,9 +1015,9 @@ uninstall-am: uninstall-libscihistory_browser_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 001e0eb..a2ad9b8 100644 (file)
@@ -1211,9 +1211,9 @@ uninstall-am: uninstall-libscihistory_manager_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index f0b0848..f8d56c0 100644 (file)
@@ -1615,9 +1615,9 @@ uninstall-am: uninstall-libsciinteger_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 0f553cf..9453736 100644 (file)
@@ -1069,9 +1069,9 @@ uninstall-am: uninstall-libsciinterpolation_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 9d86542..8972a49 100644 (file)
@@ -1135,9 +1135,9 @@ uninstall-am: uninstall-binPROGRAMS \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 59c625b..2258ca8 100644 (file)
@@ -1165,9 +1165,9 @@ uninstall-am: uninstall-libsciio_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d7160a1..d128ba1 100644 (file)
@@ -1087,9 +1087,9 @@ uninstall-am: uninstall-libjavasci_la_etcDATA \
 
 # This target enables tests for Scilab
 @JAVASCI_TRUE@check-local: $(top_builddir)/scilab-bin test
-@JAVASCI_TRUE@ @COMMAND="test_run('$(modulename)');quit";\
-@JAVASCI_TRUE@ export LANG=C;\
-@JAVASCI_TRUE@ $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+@JAVASCI_TRUE@ if test -d $(mydatadir)/tests; then \
+@JAVASCI_TRUE@   @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+@JAVASCI_TRUE@ fi
 @JAVASCI_TRUE@check-code:
 @JAVASCI_TRUE@ if test -f build.xml; then \
 @JAVASCI_TRUE@         $(ANT) checkstyle; \
index 3ce14aa..87c7752 100644 (file)
@@ -1230,9 +1230,9 @@ uninstall-am: uninstall-libscijvm_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 7973985..18ff323 100644 (file)
@@ -1401,9 +1401,9 @@ uninstall-am: uninstall-libscilinear_algebra_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 8c03b06..83eaf91 100644 (file)
@@ -1093,9 +1093,9 @@ uninstall-am: uninstall-libscilocalization_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index da020a0..5223b71 100644 (file)
@@ -683,9 +683,9 @@ uninstall-am: uninstall-libm2sci_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d093715..30211f3 100644 (file)
@@ -1161,9 +1161,9 @@ uninstall-am: uninstall-libscimatio_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 2ff371a..3a010ae 100644 (file)
@@ -959,9 +959,9 @@ uninstall-am: uninstall-libmex_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index f148171..85158a9 100644 (file)
@@ -682,9 +682,9 @@ uninstall-am: uninstall-libmodules_manager_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 7969bbc..e515315 100644 (file)
@@ -1445,9 +1445,9 @@ uninstall-am: uninstall-libscioptimization_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ccc7a23..8a506b1 100644 (file)
@@ -1352,9 +1352,9 @@ uninstall-am: uninstall-libscioutput_stream_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 083784a..1683b2f 100644 (file)
@@ -683,9 +683,9 @@ uninstall-am: uninstall-libscioverloading_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d48100b..efadfc6 100644 (file)
@@ -993,9 +993,9 @@ uninstall-am: uninstall-libsciparallel_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 244db08..7ce1131 100644 (file)
@@ -867,9 +867,9 @@ uninstall-am: uninstall-libparameters_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 8660107..05ab925 100644 (file)
@@ -1404,9 +1404,9 @@ uninstall-am: uninstall-libscipolynomials_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index abfc290..d4b5172 100644 (file)
@@ -604,9 +604,9 @@ uninstall-am:
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 45b7601..48d8649 100644 (file)
@@ -25,6 +25,7 @@ The main idea is to build at once all the var files
       <param name="target-jar" value="clean"/>
     </antcall>
   </target>
+  <target name="test"/>
   
   <target name="action_binding">
     <ant antfile="../action_binding/build.xml" target="${target-jar}" inheritRefs="false" inheritAll="false" />
index b5e88ca..d6b9306 100644 (file)
@@ -1107,9 +1107,9 @@ uninstall-am: uninstall-libscipreferences_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 7a4e3ff..8d3ffcf 100644 (file)
@@ -1104,9 +1104,9 @@ uninstall-am: uninstall-libscirandlib_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ebcac6b..871cf0c 100644 (file)
@@ -3489,9 +3489,9 @@ uninstall-am: uninstall-libscirenderer_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index c5fd690..eaf1341 100644 (file)
@@ -2139,9 +2139,9 @@ uninstall-am: uninstall-binPROGRAMS uninstall-libsciscicos_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ef80fad..87431fb 100644 (file)
@@ -4827,9 +4827,9 @@ uninstall-am: uninstall-libsciscicos_blocks_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index cf524c8..8e59cfa 100644 (file)
@@ -1060,9 +1060,9 @@ uninstall-am: uninstall-libsciscinotes_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 746b437..6972092 100644 (file)
@@ -1348,9 +1348,9 @@ uninstall-am: uninstall-libscisignal_processing_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index fdcf4e3..dd28f53 100644 (file)
@@ -688,9 +688,9 @@ uninstall-am: uninstall-libsimulated_annealing_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index c28ea13..5057572 100644 (file)
@@ -896,9 +896,9 @@ uninstall-am: uninstall-libscisound_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 43cd4b7..b494d88 100644 (file)
@@ -1711,9 +1711,9 @@ uninstall-am: uninstall-libscisparse_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d4c181a..bf664b9 100644 (file)
@@ -1116,9 +1116,9 @@ uninstall-am: uninstall-libscispecial_functions_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index cdc1679..a365739 100644 (file)
@@ -1008,9 +1008,9 @@ uninstall-am: uninstall-libscispreadsheet_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 50de2e7..756a0a3 100644 (file)
@@ -1306,9 +1306,9 @@ uninstall-am: uninstall-libscistatistics_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 6f74578..4e24107 100644 (file)
@@ -1454,9 +1454,9 @@ uninstall-am: uninstall-libscistring_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index c8b8df3..e729956 100644 (file)
@@ -972,9 +972,9 @@ uninstall-am: uninstall-libscisymbolic_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index ae57d25..9cf28f0 100644 (file)
@@ -1277,9 +1277,9 @@ uninstall-am: uninstall-libscitclsci_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 1655a8a..4cf158d 100644 (file)
@@ -1021,9 +1021,9 @@ uninstall-am: uninstall-libscitime_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 541bcb4..9a3a516 100644 (file)
@@ -1069,9 +1069,9 @@ uninstall-am: uninstall-libscitypes_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 68b3f33..cb69f75 100644 (file)
@@ -1167,9 +1167,9 @@ uninstall-am: uninstall-libsciui_data_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index d728abb..8239842 100644 (file)
@@ -1128,9 +1128,9 @@ uninstall-am: uninstall-libsciumfpack_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 2999eb4..61c336f 100644 (file)
@@ -895,9 +895,9 @@ uninstall-am: uninstall-libsciwindows_tools_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index c0adaf3..297fce8 100644 (file)
@@ -1494,9 +1494,9 @@ uninstall-am: uninstall-libscixcos_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \
index 2ada44c..d26af5c 100644 (file)
@@ -1429,9 +1429,9 @@ uninstall-am: uninstall-libscixml_la_etcDATA \
 
 # This target enables tests for Scilab
 check-local: $(top_builddir)/scilab-bin test
-       @COMMAND="test_run('$(modulename)');quit";\
-       export LANG=C;\
-       $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"
+       if test -d $(mydatadir)/tests; then \
+         @COMMAND="try test_run('$(modulename)');catch exit(-1);end;exit(0)"; export LANG=C; $(top_builddir)/bin/scilab -nwni -nb -e "$$COMMAND"; \
+       fi
 check-code:
        if test -f build.xml; then \
                $(ANT) checkstyle; \