Skip to content

Standardize Reader Conditionals #987

Standardize Reader Conditionals

Standardize Reader Conditionals #987

Workflow file for this run

name: tests
on:
pull_request:
push:
branches: [ main ]
workflow_dispatch: # Supports manual triggering
env:
# increment to "clear" the cache
CACHE_VERSION: "v1"
jobs:
test-jvm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Prepare java
uses: actions/setup-java@v5
with:
distribution: "temurin"
java-version: "21"
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@13.6.0
with:
cli: 1.12.0.1530
lein: 2.11.2
bb: latest
- name: Cache clojure dependencies
uses: actions/cache@v5
with:
path: |
~/.m2/repository
~/.gitlibs
~/.deps.clj
# List all files containing dependencies:
key: cljdeps-${{ env.CACHE_VERSION }}-${{ hashFiles('project.clj') }}-${{ hashFiles('deps.edn') }}-${{ hashFiles('bb.edn') }}
restore-keys: cljdeps-${{ env.CACHE_VERSION }}-
- name: Run Clojure tests
run: lein test
test-cljs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Prepare java
uses: actions/setup-java@v5
with:
distribution: "temurin"
java-version: "21"
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@13.6.0
with:
cli: 1.12.0.1530
lein: 2.11.2
bb: latest
- name: Cache clojure dependencies
uses: actions/cache@v5
with:
path: |
~/.m2/repository
~/.gitlibs
~/.deps.clj
# List all files containing dependencies:
key: cljdeps-${{ env.CACHE_VERSION }}-${{ hashFiles('project.clj') }}-${{ hashFiles('deps.edn') }}-${{ hashFiles('bb.edn') }}
restore-keys: cljdeps-${{ env.CACHE_VERSION }}-
- name: Prepare node
uses: actions/setup-node@v6
with:
node-version: "23.x"
check-latest: true
cache: 'npm'
cache-dependency-path: "package-lock.json"
- name: Install Node Dependencies
run: npm ci
- name: Compile ClojureScript Tests
run: npm run build
- name: Run ClojureScript Tests
run: npm test
test-bb:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Prepare java
uses: actions/setup-java@v5
with:
distribution: "temurin"
java-version: "21"
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@13.6.0
with:
cli: 1.12.0.1530
lein: 2.11.2
# Use dev build because it contains a fix not yet in a release
- name: Install babashka dev build
run: bash <(curl -s https://raw.githubusercontent.com/babashka/babashka/master/install) --dev-build --dir /tmp
- name: Cache clojure dependencies
uses: actions/cache@v5
with:
path: |
~/.m2/repository
~/.gitlibs
~/.deps.clj
# List all files containing dependencies:
key: cljdeps-${{ env.CACHE_VERSION }}-${{ hashFiles('project.clj') }}-${{ hashFiles('deps.edn') }}-${{ hashFiles('bb.edn') }}
restore-keys: cljdeps-${{ env.CACHE_VERSION }}-
- name: Run babashka tests
run: /tmp/bb test-bb
test-clr:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Prepare dotnet
uses: xt0rted/setup-dotnet@v1.5.0
- name: Install ClojureCLR
run: |
dotnet tool install --global Clojure.Main --version 1.12.3-alpha4
dotnet tool install --global Clojure.Cljr --version 0.1.0-alpha6
- name: Run ClojureCLR Tests
run: cljr -X:test
# These are disabled for now until we add some parity reporting mechanism. Our priority
# right now is filling out the test suite and newer dialects have far more failures which
# get in the way of us writing the tests. Dialect devs are still encouraged to run this
# test suite in their forks. Meanwhile, we're working on implementing a parity reporting
# mechanism so that we can enable all of these again, and more, and get nice reports
# about their compatibility.
#
#test-basilisp:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v6
# - uses: actions/setup-python@v6
# with:
# python-version: "3.14"
# - name: Install pip and dependencies
# run: |
# pip install -U pip
# python -m venv .venv
# source .venv/bin/activate
# pip install .
# - name: Run tests
# run: |
# source .venv/bin/activate
# BASILISP_TEST_PATH="$(pwd)/test" \
# BASILISP_TEST_FILE_PATTERN='.*\.(lpy|cljc)' \
# basilisp test -p test -- -n 0
#test-phel:
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# php: ['8.4', '8.5']
# steps:
# - uses: actions/checkout@v4
# - uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php }}
# coverage: none
# tools: composer
# - name: Cache Composer downloads
# uses: actions/cache@v4
# with:
# path: ~/.composer/cache
# key: composer-${{ matrix.php }}-${{ hashFiles('composer.lock') }}
# restore-keys: |
# composer-${{ matrix.php }}-
# - name: Cache Phel compiled artifacts
# uses: actions/cache@v4
# with:
# path: .phel/cache
# key: phel-cache-${{ matrix.php }}-${{ hashFiles('composer.lock', 'phel-config.php') }}-${{ hashFiles('test/**/*.cljc', 'test/**/*.phel') }}
# restore-keys: |
# phel-cache-${{ matrix.php }}-${{ hashFiles('composer.lock', 'phel-config.php') }}-
# phel-cache-${{ matrix.php }}-
# - name: Install dependencies
# run: composer install --no-interaction --no-ansi --no-progress
# - name: Run tests
# run: composer test