Shmew / Fable.Jester

Fable bindings for jest and friends for delightful Fable testing.
https://shmew.github.io/Fable.Jester/
MIT License
34 stars 4 forks source link
fable fast-check jest jest-dom property-based-testing react-testing-library testing

Fable.Jester Nuget Nuget Nuget Nuget

Fable bindings for jest and friends for delightful Fable testing:

A quick look:

Jest.describe("my tests", fun () ->
    Jest.test("water is wet", fun () ->
        Jest.expect("test").toBe("test")
        Jest.expect("test").not.toBe("somethingElse")
        Jest.expect("hi").toHaveLength(2)
        Jest.expect("hi").not.toHaveLength(3)
    )
    Jest.test.prop("Is positive", Arbitrary.ConstrainedDefaults.integer(1,100), fun i ->
        Jest.expect(i).toBeGreaterThan(0)
    )
)

Full documentation can be found here.