From 3e52c90532c5646a7af68df73375a6f4ac141d0e Mon Sep 17 00:00:00 2001 From: Yogthos Date: Mon, 8 Jun 2026 18:57:38 -0400 Subject: [PATCH] test/ci: vendor clojure-test-suite as a submodule; run it in CI MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The cross-dialect clojure-test-suite (jank-lang fork) is now a git submodule at vendor/clojure-test-suite instead of a personal ~/src checkout. The harness reads it from the vendored path only (skips cleanly if the submodule isn't initialized: `git submodule update --init`). CI already checks out submodules recursively (for vendor/sci), so the suite is now fetched and — since `jpm test` recurses through test/ — the baseline (3981 pass / 66 clean) is enforced on every push/PR. Updated the checkout comment accordingly. Co-Authored-By: Claude Opus 4.8 (1M context) --- .github/workflows/tests.yml | 4 +++- .gitmodules | 3 +++ .../integration/clojure-test-suite-test.janet | 20 +++++++++---------- vendor/clojure-test-suite | 1 + 4 files changed, 17 insertions(+), 11 deletions(-) create mode 160000 vendor/clojure-test-suite diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index c4986fc..3bf6f19 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,7 +13,9 @@ jobs: steps: - uses: actions/checkout@v4 with: - # vendor/sci is needed by the SCI bootstrap/runtime integration tests. + # Submodules: vendor/sci (SCI bootstrap/runtime tests) and + # vendor/clojure-test-suite (the cross-dialect conformance battery, + # asserted against a baseline by clojure-test-suite-test.janet). submodules: recursive - name: Cache Janet build diff --git a/.gitmodules b/.gitmodules index b878f26..959062d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,6 @@ [submodule "vendor/sci"] path = vendor/sci url = https://github.com/borkdude/sci.git +[submodule "vendor/clojure-test-suite"] + path = vendor/clojure-test-suite + url = https://github.com/jank-lang/clojure-test-suite.git diff --git a/test/integration/clojure-test-suite-test.janet b/test/integration/clojure-test-suite-test.janet index 22ab2bf..fce50c2 100644 --- a/test/integration/clojure-test-suite-test.janet +++ b/test/integration/clojure-test-suite-test.janet @@ -1,20 +1,20 @@ # clojure-test-suite conformance: runs the external, cross-dialect -# clojure-test-suite (https://github.com/lread/clojure-test-suite, EPL) against -# Jolt and asserts the number of passing per-function test files stays at/above -# a baseline. Like the jank battery, this does NOT vendor the suite — it -# references ~/src/clojure-test-suite if present and SKIPS cleanly when absent. +# clojure-test-suite (jank-lang fork) against Jolt and asserts the number of +# passing per-function test files stays at/above a baseline. The suite is a git +# submodule at vendor/clojure-test-suite (CI checks it out via submodules: +# recursive). The test SKIPS cleanly only if the submodule isn't initialized +# (run `git submodule update --init`). # # Each suite file is a `clojure.test` namespace (one per clojure.core/string # function). A minimal clojure.test + portability shim (test/support/clojure_test.clj) # lets Jolt load them; `when-var-exists` auto-skips fns Jolt doesn't implement. # # Files are run in a one-shot worker subprocess (test/integration/suite-worker.janet) -# under a wall-clock deadline. Some suite tests build infinite sequences -# (cycle/range/transducers-over-infinite) that Jolt's eager evaluator can't -# truncate and so HANG rather than fail; the deadline contains them — a timed-out -# file is reported as :timeout and contributes nothing, no manual skip-list needed. +# under a wall-clock deadline. A few suite tests build infinite sequences that an +# uncompilable/eager path can't truncate and so HANG rather than fail; the +# deadline contains them — a timed-out file contributes nothing, no skip-list. -(def suite-dir (string (os/getenv "HOME") "/src/clojure-test-suite/test/clojure")) +(def suite-dir "vendor/clojure-test-suite/test/clojure") # Baseline: assertions Jolt currently passes across the suite. Raise as Jolt # improves so a regression (previously-passing assertion breaking) is caught. @@ -86,7 +86,7 @@ result) (if (not (os/stat suite-dir)) - (print "clojure-test-suite: ~/src/clojure-test-suite not present — skipped") + (print "clojure-test-suite: vendor/clojure-test-suite not initialized — skipped (run: git submodule update --init)") (do (def progress? (os/getenv "SUITE_PROGRESS")) (def files (sort (walk suite-dir @[]))) diff --git a/vendor/clojure-test-suite b/vendor/clojure-test-suite new file mode 160000 index 0000000..e20ea02 --- /dev/null +++ b/vendor/clojure-test-suite @@ -0,0 +1 @@ +Subproject commit e20ea0289e57fe5c8b78e66865176bb7af42939d