Skip to content

Commit

Permalink
Run WASM tests
Browse files Browse the repository at this point in the history
  • Loading branch information
konsumlamm committed Dec 2, 2023
1 parent 5080716 commit 65fe3cd
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,15 @@ jobs:
export SKIP_GHC=yes
./setup.sh
source ~/.ghc-wasm/env
~/.ghc-wasm/add_to_github_path.sh
cd ..
ghcup install ghc --set ${{ env.version }} -- --host=x86_64-linux --with-intree-gmp --with-system-libffi
- name: Build
run: |
cabal --with-compiler=wasm32-wasi-ghc --with-hc-pkg=wasm32-wasi-ghc-pkg build
mv cabal.project.wasi cabal.project.local
cabal --with-compiler=wasm32-wasi-ghc --with-hc-pkg=wasm32-wasi-ghc-pkg build --enable-tests
cabal --with-compiler=wasm32-wasi-ghc --with-hc-pkg=wasm32-wasi-ghc-pkg list-bin test:bitvec-tests --enable-tests
wasmtime $(cabal --with-compiler=wasm32-wasi-ghc --with-hc-pkg=wasm32-wasi-ghc-pkg list-bin test:bitvec-tests --enable-tests)
bounds-checking:
needs: build
Expand Down
4 changes: 3 additions & 1 deletion bitvec.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ test-suite bitvec-tests
Tests.SetOps
Tests.SetOpsTS
Tests.Vector
ghc-options: -Wall -threaded -rtsopts -Wcompat
ghc-options: -Wall -Wcompat
if !arch(wasm32)
ghc-options: -threaded -rtsopts
include-dirs: test

if impl(ghc <9.0)
Expand Down
5 changes: 5 additions & 0 deletions cabal.project.wasi
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
-- https://github.com/haskellari/splitmix/pull/73
source-repository-package
type: git
location: https://github.com/amesgen/splitmix.git
tag: 83b906c4bcdc2720546f1779a16eb65e8e12ecba

0 comments on commit 65fe3cd

Please sign in to comment.