cometkim / rescript-vitest

ReScript bindings to Vitest
MIT License
42 stars 9 forks source link

unbound vi utility functions #20

Open illusionalsagacity opened 2 months ago

illusionalsagacity commented 2 months ago

Noticed a few of these are not bound yet and started working on adding them:

Current work is in this draft PR

illusionalsagacity commented 3 weeks ago

@cometkim I forgot to follow up with you on this--I have these bound in this branch but I see that in #6 you did not want to bind to the vi import. It's been a while since I looked at this but I remember there being an issue with the private vi_obj being used when I was testing this on an example project.

Would you still like to use the vi_obj private style bindings or are you ok with the zero-cost style?

cometkim commented 3 weeks ago

I see many contributors constantly mentioning binding style. It won't be zero-cost bindings, regardless of whether or not we use functors. I'm willing to accept additional runtime to fit the ReScript model.

Functors are important because I plan to add more interfaces based on it in the future. Vitest has something like test context, which should be "configurable" by users. And the functors is perfect-fit here.