Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nargo test runs test functions defined in dependencies #759

Closed
2 of 4 tasks
TomAFrench opened this issue Feb 7, 2023 · 0 comments · Fixed by #805
Closed
2 of 4 tasks

nargo test runs test functions defined in dependencies #759

TomAFrench opened this issue Feb 7, 2023 · 0 comments · Fixed by #805
Assignees
Labels
bug Something isn't working

Comments

@TomAFrench
Copy link
Member

Description

Aim

I wanted to run tests which I have written for my noir crate.

Expected behavior

nargo test should compile and run all the test functions which I have defined locally. It should not run test cases from any crates in my dependency tree (as I assume that these are correct).

Bug

As all functions are exposed from the library crate I'm importing, nargo sees these test functions and runs them as part of my test suite as if I wrote them myself.

To reproduce

  1. clone https://github.com/TomAFrench/keccak256-noir
  2. cd into circuits
  3. read main.nr to see no test functions
  4. run nargo test and see output from tests in lib directory.

Environment

  • Using nargo:

    • Binary:
    • Compiled from source: beedae6
  • Using TypeScript:

    • @noir-lang/noir_wasm:
    • @noir-lang/barretenberg:
    • @noir-lang/aztec_backend:

Additional context

@TomAFrench TomAFrench added the bug Something isn't working label Feb 7, 2023
jfecher added a commit that referenced this issue Feb 10, 2023

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
kevaundray added a commit that referenced this issue Feb 11, 2023
…current module (#805)

* Fix #759

* Change unwrap to expect

---------

Co-authored-by: kevaundray <kevtheappdev@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants