File tree 2 files changed +16
-8
lines changed
2 files changed +16
-8
lines changed Original file line number Diff line number Diff line change @@ -25,22 +25,27 @@ jobs:
25
25
- { os: ubuntu-20.04, toolchain: wasm-5.7.1-RELEASE, wasi-backend: MicroWASI }
26
26
27
27
runs-on : ${{ matrix.entry.os }}
28
+ env :
29
+ JAVASCRIPTKIT_WASI_BACKEND : ${{ matrix.entry.wasi-backend }}
30
+ SWIFT_VERSION : ${{ matrix.entry.toolchain }}
28
31
steps :
29
32
- name : Checkout
30
33
uses : actions/checkout@master
31
34
with :
32
35
fetch-depth : 1
33
- - name : Run Test
34
- env :
35
- JAVASCRIPTKIT_WASI_BACKEND : ${{ matrix.entry.wasi-backend }}
36
+ - name : Install swiftenv
36
37
run : |
37
38
git clone https://github.com/kylef/swiftenv.git ~/.swiftenv
38
39
export SWIFTENV_ROOT="$HOME/.swiftenv"
39
40
export PATH="$SWIFTENV_ROOT/bin:$PATH"
40
41
eval "$(swiftenv init -)"
41
- SWIFT_VERSION=${{ matrix.entry.toolchain }} make bootstrap
42
+ echo $PATH >> $GITHUB_PATH
43
+ env >> $GITHUB_ENV
42
44
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.') }}
44
49
- name : Check if SwiftPM resources are stale
45
50
run : |
46
51
make regenerate_swiftpm_resources
Original file line number Diff line number Diff line change @@ -12,16 +12,19 @@ build:
12
12
13
13
.PHONY : test
14
14
test :
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
18
15
@echo Running integration tests
19
16
cd IntegrationTests && \
20
17
CONFIGURATION=debug make test && \
21
18
CONFIGURATION=debug SWIFT_BUILD_FLAGS=" -Xswiftc -DJAVASCRIPTKIT_WITHOUT_WEAKREFS" make test && \
22
19
CONFIGURATION=release make test && \
23
20
CONFIGURATION=release SWIFT_BUILD_FLAGS=" -Xswiftc -DJAVASCRIPTKIT_WITHOUT_WEAKREFS" make test
24
21
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
+
25
28
.PHONY : benchmark_setup
26
29
benchmark_setup :
27
30
cd IntegrationTests && CONFIGURATION=release make benchmark_setup
You can’t perform that action at this time.
0 commit comments