Add tests for when-not
#758
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 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@v4 | |
| - name: Prepare java | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: "temurin" | |
| java-version: "21" | |
| - name: Install clojure tools | |
| uses: DeLaGuardo/[email protected] | |
| with: | |
| cli: 1.12.0.1530 | |
| lein: 2.11.2 | |
| bb: latest | |
| - name: Cache clojure dependencies | |
| uses: actions/cache@v4 | |
| 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@v4 | |
| - name: Prepare java | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: "temurin" | |
| java-version: "21" | |
| - name: Install clojure tools | |
| uses: DeLaGuardo/[email protected] | |
| with: | |
| cli: 1.12.0.1530 | |
| lein: 2.11.2 | |
| bb: latest | |
| - name: Cache clojure dependencies | |
| uses: actions/cache@v4 | |
| 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@v4 | |
| 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@v4 | |
| - name: Prepare java | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: "temurin" | |
| java-version: "21" | |
| - name: Install clojure tools | |
| uses: DeLaGuardo/[email protected] | |
| with: | |
| cli: 1.12.0.1530 | |
| lein: 2.11.2 | |
| bb: latest | |
| - name: Cache clojure dependencies | |
| uses: actions/cache@v4 | |
| 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: bb test-bb | |
| test-clr: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Prepare dotnet | |
| uses: xt0rted/[email protected] | |
| - 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 | |
| test-basilisp: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.13" | |
| - 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 auto |