aboutsummaryrefslogtreecommitdiffstats
path: root/common.mk
diff options
context:
space:
mode:
authorYusuke Endoh <mame@ruby-lang.org>2019-07-21 19:19:08 +0900
committerYusuke Endoh <mame@ruby-lang.org>2019-07-21 19:19:08 +0900
commit24712eeec39f5e9a11cfc2b940358403cda4f2b6 (patch)
tree1c73137b5a00c1ae13ee6d72256df4d23c2fd593 /common.mk
parent523fec8a4baec1e2a9c1adc0095646b12aa6c76c (diff)
downloadruby-24712eeec39f5e9a11cfc2b940358403cda4f2b6.tar.gz
tool/test/runner.rb: support --test-target-dir option
tool/test/runner.rb had been copied from test/runner.rb. test/runner.rb was for `make test-all`, and tool/test/runner.rb was for `make test-testframework` and `make test-tool`. But I want to avoid the code clones. This change makes tool/test/runner.rb support --test-target-dir option which allows tool/test/runner.rb to run `make test-all`. Now we can remove test/runner.rb.
Diffstat (limited to 'common.mk')
-rw-r--r--common.mk10
1 files changed, 5 insertions, 5 deletions
diff --git a/common.mk b/common.mk
index 63312b5fb1..da81afa418 100644
--- a/common.mk
+++ b/common.mk
@@ -754,12 +754,12 @@ yes-test-knownbug: prog PHONY
test-testframework: $(TEST_RUNNABLE)-test-testframework
yes-test-testframework: prog PHONY
- $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --ruby="$(RUNRUBY)" --basedir=$(TOOL_TESTSDIR) $(TESTOPTS) testunit minitest
+ $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --test-target-dir="$(TOOL_TESTSDIR)" -- --ruby="$(RUNRUBY)" $(TESTOPTS) testunit minitest
no-test-testframework: PHONY
test-tool: $(TEST_RUNNABLE)-test-tool
yes-test-tool: prog PHONY
- $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --ruby="$(RUNRUBY)" --basedir=$(TOOL_TESTSDIR) $(TESTOPTS) $(EXCLUDE_TESTFRAMEWORK)
+ $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --test-target-dir="$(TOOL_TESTSDIR)" -- --ruby="$(RUNRUBY)" $(TESTOPTS) $(EXCLUDE_TESTFRAMEWORK)
no-test-tool: PHONY
test-sample: test-basic # backward compatibility for mswin-build
@@ -770,10 +770,10 @@ test: test-short
# for example, make test-all TESTOPTS="-j2 -v -n test-name -- test-file-name"
test-all: $(TEST_RUNNABLE)-test-all
yes-test-all: programs PHONY
- $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(srcdir)/test/runner.rb" --ruby="$(RUNRUBY)" $(TEST_EXCLUDES) $(TESTOPTS) $(TESTS)
+ $(gnumake_recursive)$(Q)$(exec) $(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --test-target-dir="$(TESTSDIR)" -- --ruby="$(RUNRUBY)" $(TEST_EXCLUDES) $(TESTOPTS) $(TESTS)
TESTS_BUILD = mkmf
no-test-all: PHONY
- $(gnumake_recursive)$(MINIRUBY) -I"$(srcdir)/lib" "$(srcdir)/test/runner.rb" $(TESTOPTS) $(TESTS_BUILD)
+ $(gnumake_recursive)$(MINIRUBY) -I"$(srcdir)/lib" "$(TOOL_TESTSDIR)/runner.rb" --test-target-dir="$(TESTSDIR)" -- $(TESTOPTS) $(TESTS_BUILD)
test-almost: test-all
yes-test-almost: yes-test-all
@@ -782,7 +782,7 @@ no-test-almost: no-test-all
test-ruby: $(TEST_RUNNABLE)-test-ruby
no-test-ruby: PHONY
yes-test-ruby: prog encs PHONY
- $(gnumake_recursive)$(RUNRUBY) "$(srcdir)/test/runner.rb" $(TEST_EXCLUDES) $(TESTOPTS) -- ruby -ext-
+ $(gnumake_recursive)$(RUNRUBY) "$(TOOL_TESTSDIR)/runner.rb" --test-target-dir="$(TESTSDIR)" -- $(TEST_EXCLUDES) $(TESTOPTS) -- ruby -ext-
extconf: $(PREP)
$(Q) $(MAKEDIRS) "$(EXTCONFDIR)"