File tree Expand file tree Collapse file tree 2 files changed +16
-8
lines changed Expand file tree Collapse file tree 2 files changed +16
-8
lines changed Original file line number Diff line number Diff line change @@ -25,22 +25,27 @@ jobs:
2525 - { os: ubuntu-20.04, toolchain: wasm-5.7.1-RELEASE, wasi-backend: MicroWASI }
2626
2727 runs-on : ${{ matrix.entry.os }}
28+ env :
29+ JAVASCRIPTKIT_WASI_BACKEND : ${{ matrix.entry.wasi-backend }}
30+ SWIFT_VERSION : ${{ matrix.entry.toolchain }}
2831 steps :
2932 - name : Checkout
3033 uses : actions/checkout@master
3134 with :
3235 fetch-depth : 1
33- - name : Run Test
34- env :
35- JAVASCRIPTKIT_WASI_BACKEND : ${{ matrix.entry.wasi-backend }}
36+ - name : Install swiftenv
3637 run : |
3738 git clone https://github.com/kylef/swiftenv.git ~/.swiftenv
3839 export SWIFTENV_ROOT="$HOME/.swiftenv"
3940 export PATH="$SWIFTENV_ROOT/bin:$PATH"
4041 eval "$(swiftenv init -)"
41- SWIFT_VERSION=${{ matrix.entry.toolchain }} make bootstrap
42+ echo $PATH >> $GITHUB_PATH
43+ env >> $GITHUB_ENV
4244 echo ${{ matrix.entry.toolchain }} > .swift-version
43- make test
45+ - run : make bootstrap
46+ - run : make test
47+ - run : make unittest
48+ if : ${{ startsWith(matrix.toolchain, 'wasm-5.7.') }}
4449 - name : Check if SwiftPM resources are stale
4550 run : |
4651 make regenerate_swiftpm_resources
Original file line number Diff line number Diff line change @@ -12,16 +12,19 @@ build:
1212
1313.PHONY : test
1414test :
15- @echo Running unit tests
16- swift build --build-tests --triple wasm32-unknown-wasi -Xswiftc -Xclang-linker -Xswiftc -mexec-model=reactor -Xlinker --export=main
17- node --experimental-wasi-unstable-preview1 scripts/test-harness.js ./.build/wasm32-unknown-wasi/debug/JavaScriptKitPackageTests.wasm
1815 @echo Running integration tests
1916 cd IntegrationTests && \
2017 CONFIGURATION=debug make test && \
2118 CONFIGURATION=debug SWIFT_BUILD_FLAGS=" -Xswiftc -DJAVASCRIPTKIT_WITHOUT_WEAKREFS" make test && \
2219 CONFIGURATION=release make test && \
2320 CONFIGURATION=release SWIFT_BUILD_FLAGS=" -Xswiftc -DJAVASCRIPTKIT_WITHOUT_WEAKREFS" make test
2421
22+ .PHONY : unittest
23+ unittest :
24+ @echo Running unit tests
25+ swift build --build-tests --triple wasm32-unknown-wasi -Xswiftc -Xclang-linker -Xswiftc -mexec-model=reactor -Xlinker --export=main
26+ node --experimental-wasi-unstable-preview1 scripts/test-harness.js ./.build/wasm32-unknown-wasi/debug/JavaScriptKitPackageTests.wasm
27+
2528.PHONY : benchmark_setup
2629benchmark_setup :
2730 cd IntegrationTests && CONFIGURATION=release make benchmark_setup
You can’t perform that action at this time.
0 commit comments