Added test/runner to run individual test cases
The check/test/test-suite make targets can still be used, but this at least allows running specific test cases from the command line, which is extremely useful during development.perfodd
parent
ff07b4f456
commit
9a3a71bc33
|
@ -9,6 +9,7 @@ NEWS
|
|||
ChangeLog
|
||||
|
||||
# autotools- and configure-generated
|
||||
test/runner
|
||||
aclocal.m4
|
||||
Makefile.in
|
||||
Makefile
|
||||
|
|
|
@ -34,7 +34,7 @@ path_combine_output_full_min = $(path_combine_output_full:.js=.min.js)
|
|||
src_js = @SRC_JS@
|
||||
path_externs_internal = $(path_build)/externs-internal.js
|
||||
|
||||
test_cases=$(shell find test/ -name '*Test.*' | tr '\n' ' ' )
|
||||
test_cases=$(shell cd test/ && find . -name '*Test.*' | tr '\n' ' ' )
|
||||
src_tests=$(shell find test/ -name test-* | tr '\n' ' ' )
|
||||
|
||||
combine = $(path_tools)/combine
|
||||
|
@ -130,8 +130,7 @@ test-suite:
|
|||
if HAS_NODE
|
||||
@echo "GNU ease.js Test Suite"
|
||||
@echo
|
||||
@NODE_PATH="$(path_test):.:$(NODE_PATH)" $(NODE) --stack_trace_limit=20 \
|
||||
$(path_test)/runner.js $(test_cases)
|
||||
@(cd $(path_test) && ./runner $(test_cases))
|
||||
else
|
||||
@echo "Node.js must be installed in order to run the test suite"
|
||||
@exit 1
|
||||
|
|
|
@ -87,5 +87,7 @@ PERF_TESTS=$( find test/perf -name 'perf-*.js' | tr '\n' ' ' )
|
|||
AC_SUBST(PERF_TESTS)
|
||||
AS_IF([test "$PERF_TESTS"], [AC_MSG_RESULT(ok)], [AC_MSG_WARN(none found)])
|
||||
|
||||
AC_CONFIG_FILES([Makefile doc/Makefile package.json lib/version.js])
|
||||
AC_CONFIG_FILES(
|
||||
[Makefile doc/Makefile package.json lib/version.js test/runner],
|
||||
[chmod +x test/runner])
|
||||
AC_OUTPUT
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Copyright (C) 2014 Mike Gerwitz
|
||||
#
|
||||
# This file is part of GNU ease.js.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# #
|
||||
|
||||
NODE_PATH=".:$NODE_PATH" @NODE@ --stack-trace-limit=20 \
|
||||
./runner.js "$@"
|
Loading…
Reference in New Issue