Skip to content

Does using "bazel test" work? #883

Closed

Description

@spyle2

I cant seem to use bazel to run a test that includes "emscripten.h" or any other emscripten libs.
I wrote a cc_test and use --config=wasm and have gone through many, many errors that I am slowly working through. cc_binary/cc_libary work fine using "bazel build --config=wasm".

I have gone through many errors; so manual editing of the toolchain flags fixed most. Currently I am stuck on it not being able to include node_modules.

internal/modules/cjs/loader.js:797
    throw err;
    ^

Error: Cannot find module './lib/utils'
Require stack:

That specific error isn't really my main question. I really want to know if anyone has gotten cc_test to work at all with including emscripten libs?
Should we create a wasm_cc_test?

Activity

  1. walkingeyerobot commented on Sep 7, 2021

    @walkingeyerobot
    Collaborator

    I can confirm that bazel test does not currently work.

  2. sbc100 commented on Aug 7, 2026

    @sbc100
    Collaborator

    @DoDoENT @walkingeyerobot do you if this works now?

  3. DoDoENT commented on Aug 7, 2026

    @DoDoENT
    Collaborator
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions