Releases: cometkim/rescript-vitest
Releases · cometkim/rescript-vitest
v2.0.0
What's Changed
Full Changelog: v1.5.0...v2.0.0
Context bindings
You should now bind test context explicitly on expect
/ assertions
/ hasAssertions
test("My test case", t => {
- expect(1 + 2)->Expect.toBe(3)
+ t->expect(1+2)->Expect.toBe(3)
})
This ensures the test context is always bound correctly, even in the InSource
testing. If you want to keep the old code style, you can open the built-in Vitest.Bindings.BuiltIn
, which binds Vitest's built-in global test context as before.
Simple flags
You can now use flags like skip
, only
, concurrent
, etc as the suite's named arguments.
test(~skip=true, "Skipped test", t => { ... })
test(~only=true, "Only test", t => { ... })
(Now I'm considering module-style bindings to keep bindings simple, but still not sure which one users prefer them yet)
Compiler support
rescript-vitest now works for ReScript v10, v11, and v12, regardless uncurried mode
Dependencies
Update Vitest to v2.1.8, which supports Vite 6
v1.5.0
What's Changed
- Binds more Vi utilities, and creates tests by @illusionalsagacity in #25
- Upgrade Vitest to v1.6.0 (See upstream changes)
Full Changelog: v1.4.0...v1.5.0
v1.4.0
What's Changed
- Update vitest to v1.5.0
- fix List matchers in #21
- Compiles with ReScript v11 by @illusionalsagacity in #18
- Add binding for
Array.toContainEqual
andList.toContainEqual
by @illusionalsagacity in #22
Non-feature
- Fix a typo in README.md by @brettcannon in #24
- Adds tests for assertions/expect by @illusionalsagacity in #23
New Contributors
- @illusionalsagacity made their first contribution in #18
- @brettcannon made their first contribution in #24
Full Changelog: v1.3.0...v1.4.0
v1.3.0
v1.2.0
v1.1.0
v1.0.1
v1.0.0
- BREAKING: ReScript v10.1 is required.
- Switch
@ryyppy/rescript-promise
toJs.Promise2
for async/await compatibility. - Fixed
Expect.not
binding correctly - Added
Expect.toBeSome
andExpect.toBeNone
- Added
Expect.Promise
matchers. (Seepromise.test.res
for detail) - Added aliases
testAsync
anditAsync
, which are identical totestPromise
anditPromise