Stream: contributing

Topic: ✔ failing test


view this post on Zulip Brendan Hansknecht (Mar 11 2023 at 22:00):

Locally, tests::opaque_wrap_function in repl_test is failing for me on main. Is anyone else seeing this:

cargo test -p repl_test --lib -- tests::opaque_wrap_function

view this post on Zulip Brendan Hansknecht (Mar 11 2023 at 22:16):

oh, it is an issue with dirty builds and the test using a version of roc I built on another branch.

view this post on Zulip Folkert de Vries (Mar 11 2023 at 22:18):

ah yup

view this post on Zulip Folkert de Vries (Mar 11 2023 at 22:18):

also happens to me from time to time, and then I remember

view this post on Zulip Richard Feldman (Mar 11 2023 at 22:43):

so cargo clean is the fix then?

view this post on Zulip Folkert de Vries (Mar 11 2023 at 22:44):

no, cargo build

view this post on Zulip Folkert de Vries (Mar 11 2023 at 22:44):

that updates the roc binary that the test invokes

view this post on Zulip Norbert Hajagos (Jun 11 2023 at 14:07):

Hi! First time trying contributing to open source. I wanted to run the tests before touching anything.
On my x86_64 linux, on main branch, running cargo test -p roc_glue --test test_glue_cli fails (0 passed; 17 failed; 1 ignored). I've cargo clean -ed the directory, entered the nix dev shell, ran cargo build and then run the tests. Is this known, and should I just ignore this?

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 14:23):

Yep, known

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 14:23):

Those tests require the roc executive to be built before they can run

view this post on Zulip Norbert Hajagos (Jun 11 2023 at 14:30):

Does the latest release-mode compiled roc binary have to be in the path, or something like that? Asking, since I ran cargo build beforehand.

view this post on Zulip Richard Feldman (Jun 11 2023 at 15:29):

we should really fix this

view this post on Zulip Richard Feldman (Jun 11 2023 at 15:29):

cargo test should just work without cleaning

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 16:56):

Hmm. I thought it should work with regular cargo build

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 16:56):

let me double check how we are doing this

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 16:58):

Hmm. According to our code, the tests should compile the roc binary if it doesn't exist.

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 17:47):

I'll have a fix up shortly

view this post on Zulip Brendan Hansknecht (Jun 11 2023 at 18:06):

#5541 should fix this

view this post on Zulip Notification Bot (Jun 14 2023 at 11:55):

Anton has marked this topic as resolved.


Last updated: Jul 06 2025 at 12:14 UTC