Skip to content

Commit dc876c6

Browse files
aykevldeadprogram
authored andcommitted
ci: add single test for wasm
It looks like we didn't have any tests for wasm. Having one tests is not much, but it proves that the infrastructure works and it actually verifies a fix to tinygo-org#4777. We should add more packages to this list in the future.
1 parent 5a09084 commit dc876c6

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

.github/workflows/linux.yml

+1
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@ jobs:
165165
ln -s ~/lib/tinygo/bin/tinygo ~/go/bin/tinygo
166166
- run: make tinygo-test-wasip1-fast
167167
- run: make tinygo-test-wasip2-fast
168+
- run: make tinygo-test-wasm
168169
- run: make smoketest
169170
assert-test-linux:
170171
# Run all tests that can run on Linux, with LLVM assertions enabled to catch

GNUmakefile

+5
Original file line numberDiff line numberDiff line change
@@ -407,6 +407,9 @@ TEST_PACKAGES_WINDOWS := \
407407
text/template/parse \
408408
$(nil)
409409

410+
TEST_PACKAGES_WASM := \
411+
crypto/sha256
412+
410413
# Report platforms on which each standard library package is known to pass tests
411414
jointmp := $(shell echo /tmp/join.$$$$)
412415
report-stdlib-tests-pass:
@@ -450,6 +453,8 @@ tinygo-bench-fast:
450453
$(TINYGO) test -bench . $(TEST_PACKAGES_HOST)
451454

452455
# Same thing, except for wasi rather than the current platform.
456+
tinygo-test-wasm:
457+
$(TINYGO) test -target wasm $(TEST_PACKAGES_WASM)
453458
tinygo-test-wasi:
454459
$(TINYGO) test -target wasip1 $(TEST_PACKAGES_FAST) $(TEST_PACKAGES_SLOW) ./tests/runtime_wasi
455460
tinygo-test-wasip1:

0 commit comments

Comments
 (0)