From c8382264a4dcbee8e21de2597f181f6c0b3fad2f Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Wed, 15 Nov 2023 20:30:14 +0200 Subject: [PATCH] ci,tools: remove skips for the wasm backend, since binaryen is not required anymore (#19883) --- .github/workflows/wasm_backend_tests_ci.yml | 40 +++++++-------------- cmd/tools/modules/testing/common.v | 10 ------ cmd/tools/vtest-self.v | 4 --- 3 files changed, 12 insertions(+), 42 deletions(-) diff --git a/.github/workflows/wasm_backend_tests_ci.yml b/.github/workflows/wasm_backend_tests_ci.yml index 753e6fef9c891b..75e5d5aa50c9ff 100644 --- a/.github/workflows/wasm_backend_tests_ci.yml +++ b/.github/workflows/wasm_backend_tests_ci.yml @@ -52,27 +52,20 @@ jobs: steps: - uses: actions/checkout@v3 - - name: Install dependencies - run: | - sudo apt-get update - sudo apt-get install --quiet -y clang gcc - - name: Build V - run: make -j4 && ./v symlink -githubci + run: make && ./v symlink -githubci + + - name: Build examples + run: VTEST_ONLY=wasm ./v build-examples - name: Install wasmer to execute WASM modules run: | curl https://get.wasmer.io -sSfL | sh sudo ln -s ~/.wasmer/bin/wasmer /usr/local/bin - - name: Build the V WASM backend - run: ./v -cc clang -showcc -v cmd/tools/builders/wasm_builder.v - - name: Test the WASM backend - run: ./v test vlib/v/gen/wasm/tests/ + run: ./v -stats test vlib/v/gen/wasm/tests/ - - name: Build examples - run: VTEST_ONLY=wasm ./v build-examples wasm-backend-macos: runs-on: macOS-12 @@ -82,21 +75,18 @@ jobs: - uses: actions/checkout@v3 - name: Build V - run: make -j4 && ./v symlink -githubci + run: make && ./v symlink -githubci + + - name: Build examples + run: VTEST_ONLY=wasm ./v build-examples - name: Install wasmer to execute WASM modules run: | curl https://get.wasmer.io -sSfL | sh sudo ln -s ~/.wasmer/bin/wasmer /usr/local/bin - - name: Build the V WASM backend - run: ./v -cc clang -showcc -v cmd/tools/builders/wasm_builder.v - - name: Test the WASM backend - run: ./v test vlib/v/gen/wasm/tests/ - - - name: Build examples - run: VTEST_ONLY=wasm ./v build-examples + run: ./v -stats test vlib/v/gen/wasm/tests/ # wasm-backend-windows: # runs-on: windows-2022 @@ -110,14 +100,8 @@ jobs: # - name: Symlink V # run: .\v.exe symlink -githubci # -# - name: Install binaryen as build dependency for the V WASM backend -# run: v cmd/tools/install_binaryen.vsh -# -# - name: Build the V WASM backend -# run: v -cc msvc -showcc -v cmd/tools/builders/wasm_builder.v +# - name: Build examples +# run: $env:VTEST_ONLY='wasm'; v build-examples # # - name: Test the WASM backend # run: v -stats test vlib/v/gen/wasm/tests/ -# -# - name: Build examples -# run: $env:VTEST_ONLY='wasm'; v build-examples diff --git a/cmd/tools/modules/testing/common.v b/cmd/tools/modules/testing/common.v index 782d4337340c43..d776537439fe31 100644 --- a/cmd/tools/modules/testing/common.v +++ b/cmd/tools/modules/testing/common.v @@ -276,16 +276,6 @@ pub fn new_test_session(_vargs string, will_compile bool) TestSession { } // examples/wasm/mandelbrot/mandelbrot.v requires special compilation flags: `-b wasm -os browser`, skip it for now: skip_files << 'examples/wasm/mandelbrot/mandelbrot.v' - - // TODO: always build the wasm_builder in the future, not just when it was build manually before: - wasm_builder_executable := $if !windows { - 'cmd/tools/builders/wasm_builder' - } $else { - 'cmd/tools/builders/wasm_builder.exe' - } - if !os.exists(wasm_builder_executable) { - skip_files << os.join_path('cmd/tools/builders/wasm_builder.v') - } } vargs := _vargs.replace('-progress', '') vexe := pref.vexe_path() diff --git a/cmd/tools/vtest-self.v b/cmd/tools/vtest-self.v index bf9594fc0dfd21..2d410050eb212f 100644 --- a/cmd/tools/vtest-self.v +++ b/cmd/tools/vtest-self.v @@ -354,10 +354,6 @@ fn main() { } } - if !os.exists('cmd/tools/builders/wasm_builder') { - tsession.skip_files << 'vlib/v/gen/wasm/tests/wasm_test.v' - } - mut werror := false mut sanitize_memory := false mut sanitize_address := false