Module

ViTest.Expect.Either

Package
purescript-vitest
Repository
rowtype-yoga/purescript-vitest

#expectRight Source

expectRight :: forall e a. Eq a => Show e => a -> Either e a -> Aff Unit

Assert that a value is Right with a specific value

#expectIsRight Source

expectIsRight :: forall e a. Show e => Either e a -> Aff Unit

Assert that a value is Right (don't care about the value)

#expectLeft Source

expectLeft :: forall e a. Eq e => Show a => e -> Either e a -> Aff Unit

Assert that a value is Left with a specific error

#expectIsLeft Source

expectIsLeft :: forall e a. Show a => Either e a -> Aff Unit

Assert that a value is Left (don't care about the error)

#expectLeftContains Source

expectLeftContains :: forall a. Show a => String -> Either String a -> Aff Unit

Assert that a Left contains a specific substring in its error

#indexOfImpl Source