From d97423d3854a1b5d0b286b29762860d265c4c0f0 Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Mon, 31 Jul 2023 10:57:57 +0300 Subject: [PATCH] tools: add a test for `v -os wasm32_emscripten examples/2048` in `v test-all` --- cmd/tools/vtest-all.v | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cmd/tools/vtest-all.v b/cmd/tools/vtest-all.v index 50c234af03..39192c36be 100644 --- a/cmd/tools/vtest-all.v +++ b/cmd/tools/vtest-all.v @@ -180,6 +180,15 @@ fn get_all_commands() []Command { okmsg: 'V can compile 2048 with -skip-unused.' rmfile: 'examples/2048/2048' } + if _ := os.find_abs_path_of_executable('emcc') { + res << Command{ + line: '${vexe} -os wasm32_emscripten examples/2048' + okmsg: 'V can compile 2048 with -os wasm32_emscripten, using emcc.' + rmfile: 'examples/2048/2048' + } + } else { + println('> emcc not found, skipping `v -os wasm32_emscripten examples/2048`.') + } res << Command{ line: '${vexe} -skip-unused -live examples/hot_reload/bounce.v' okmsg: 'V can compile the hot code reloading bounce.v example with both: -skip-unused -live'