-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/

-- | Tasty helpers to test HsLua.
--   
--   Various tasty helpers and utilities to test HsLua oparations. Built on
--   top of tasty-hunit.
@package tasty-hslua
@version 1.1.1

-- | Utilities for testing of HsLua operations.
module Test.Tasty.HsLua

-- | Checks whether the operation returns True.
assertLuaBool :: HasCallStack => LuaE e Bool -> Assertion

-- | Takes a Lua expression as a ByteString, evaluates it and pushes
--   the result to the stack.
--   
--   
--   -- will return "12"
--   run $ do
--     pushLuaExpr "7 + 5"
--     tointeger top
--   
pushLuaExpr :: LuaError e => ByteString -> LuaE e ()

-- | Checks whether a Lua operation fails with the given string as
--   error message.
shouldBeErrorMessageOf :: (HasCallStack, Show a) => String -> Lua a -> Assertion

-- | Takes a value and a Lua operation and turns them into an
--   Assertion which checks that the operation produces the given
--   value.
shouldBeResultOf :: (HasCallStack, Eq a, Show a) => a -> Lua a -> Assertion

-- | Checks whether the return value of an operation holds for the given
--   predicate.
shouldHoldForResultOf :: (HasCallStack, Show a) => (a -> Bool) -> Lua a -> Assertion

-- | Infix alias for testCase.
(=:) :: String -> Assertion -> TestTree
infix 3 =:

-- | Infix alias for luaTestBool.
(?:) :: HasCallStack => String -> LuaE e Bool -> TestTree
infixr 3 ?:
