Skip to content

Commit

Permalink
Remove hoistExample
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasjm committed Oct 17, 2024
1 parent 4f08cf3 commit 91ade7c
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions sandwich-webdriver/src/Test/Sandwich/WebDriver/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,21 +20,16 @@ module Test.Sandwich.WebDriver.Types (
-- * The Xvfb session
, XvfbSession(..)
, getXvfbSession

-- * Misc helpers
, hoistExample
) where

import Control.Monad.Catch (MonadMask)
import Control.Monad.IO.Class
import Control.Monad.IO.Unlift
import Control.Monad.Reader
import Control.Monad.Trans.Control (MonadBaseControl)
import Data.IORef
import GHC.Stack
import Test.Sandwich
import Test.Sandwich.Contexts.Files
import Test.Sandwich.Internal
import Test.Sandwich.WebDriver.Internal.Dependencies
import Test.Sandwich.WebDriver.Internal.Types
import qualified Test.WebDriver.Class as W
Expand Down Expand Up @@ -76,9 +71,5 @@ type ContextWithBaseDeps context =
-- | Base context
:> context

hoistExample :: ExampleT context IO a -> ExampleT (LabelValue "webdriverSession" WebDriverSession :> context) IO a
hoistExample (ExampleT r) = ExampleT $ transformContext r
where transformContext = withReaderT (\(_ :> ctx) -> ctx)

type BaseMonad m context = (HasCallStack, MonadUnliftIO m, MonadMask m, HasBaseContext context)
type WebDriverMonad m context = (HasCallStack, MonadUnliftIO m, HasWebDriverContext context)

0 comments on commit 91ade7c

Please sign in to comment.