]> git.kaiwu.me - quickjs.git/commitdiff
handle missing test262 gracefully
authorCharlie Gordon <github@chqrlie.org>
Sat, 17 Feb 2024 21:56:54 +0000 (22:56 +0100)
committerCharlie Gordon <github@chqrlie.org>
Sat, 17 Feb 2024 21:56:54 +0000 (22:56 +0100)
Makefile

index 93a886fc51b1117aa9225d8af061e5bf12249675..df0d87317eb2050809ce57e08eea2be05a9cdd6f 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -482,6 +482,10 @@ microbench: qjs
 microbench-32: qjs32
        ./qjs32 --std tests/microbench.js
 
+ifeq ($(wildcard test262o/tests.txt),)
+test2o test2o-32 test2o-update:
+       @echo test262o tests not installed
+else
 # ES5 tests (obsolete)
 test2o: run-test262
        time ./run-test262 -m -c test262o.conf
@@ -491,7 +495,12 @@ test2o-32: run-test262-32
 
 test2o-update: run-test262
        ./run-test262 -u -c test262o.conf
+endif
 
+ifeq ($(wildcard test262o/tests.txt),)
+test2 test2-32 test2-update test2-default test2-check:
+       @echo test262 tests not installed
+else
 # Test262 tests
 test2-default: run-test262
        time ./run-test262 -m -c test262.conf
@@ -507,6 +516,7 @@ test2-update: run-test262
 
 test2-check: run-test262
        time ./run-test262 -m -c test262.conf -E -a
+endif
 
 testall: all test microbench test2o test2