hirosystems/clarinet

Can't find variable `simnet` when running tests using `bun test`

matronator opened this issue · 3 comments

Describe the bug
I don't know if this is a bug with bun as I haven't tried running the tests with npm test to see if it also fails. But when using bun test it throws an error that it can't find variable simnet. I had to add it manually to the test file (import and init). So it seems like the vitest before hooks are not working properly, at least when using bun.

To Reproduce
Steps to reproduce the behavior:

  1. Run clarinet contracts new <name>
  2. bun i
  3. bun test
  4. The test errors

Additional context here:

Note that bun test is not the same as npm run test, bun test uses bun:test. If you want to run the "test" package.json script with Bun, you can instead do bun run test.

Note that bun test is not the same as npm run test, bun test uses bun:test. If you want to run the "test" package.json script with Bun, you can instead do bun run test.

Oh my god, you're right! Oops, sorry, I guess this is not an issue then.

Hey @matronator, let me know if you have any feedback jsong the clarinet-sdk with Bun (performances and everything).

@Jarred-Sumner Thank you so much for taking the time to answer here 🙏