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


-- | A desktop bar similar to xmobar, but with more GUI
--   
--   A desktop bar similar to xmobar, but with more GUI
@package taffybar
@version 4.1.1

module System.Taffybar.Test.UtilSpec
spec :: Spec

-- | Run the given <a>IO</a> action with the <tt>PATH</tt> environment
--   variable set up so that executing the given command name will run a
--   script.
withMockCommand :: FilePath -> String -> IO a -> IO a

-- | Write a text file, make it executable. It ought to have a shebang
--   line.
writeScript :: FilePath -> String -> IO ()

-- | Run an <a>IO</a> action with the given environment variables set up
--   according to their current value. <a>Nothing</a> denotes an unset
--   environment variable. After the <a>IO</a> action completes,
--   environment variables are restored to their previous state.
withEnv :: [(String, Maybe String -> Maybe String)] -> IO a -> IO a
withSetEnv :: [(String, String)] -> IO a -> IO a

-- | Use this as a modifier function argument of <a>withEnv</a> to ensure
--   that the given directory is prepended to a search path variable.
prependPath :: FilePath -> Maybe String -> Maybe String

-- | Like <tt>withProcessTerm_</tt>, except that if the process exits --
--   for whatever reason -- before the action completes, then it's an
--   error. It will immediately cancel the action and throw an
--   <a>ExitCodeException</a>.
withService :: MonadUnliftIO m => ProcessConfig stdin stdout stderr -> (Process stdin stdout stderr -> m a) -> m a
setStdoutCond :: Priority -> ProcessConfig i o e -> ProcessConfig i () e
setStderrCond :: Priority -> ProcessConfig i o e -> ProcessConfig i o ()
setServiceDefaults :: Priority -> ProcessConfig i o e -> ProcessConfig () () ()
makeServiceDefaults :: FilePath -> [String] -> IO (ProcessConfig () () ())
listLiveThreads :: IO [(ThreadId, (String, Maybe ThreadStatus))]
diffLiveThreads :: Eq a => [(a, b)] -> [(a, b)] -> [(a, b)]
listFds :: MonadIO m => m [(Int, FilePath)]
tryIOMaybe :: MonadUnliftIO m => m a -> m (Maybe a)
laxTimeout :: (HasCallStack, MonadUnliftIO m) => Int -> m a -> m (Maybe a)
laxTimeout' :: (HasCallStack, MonadUnliftIO m) => Int -> m a -> m a

-- | A wrapper to provide <a>Eq</a> for types which only have <a>Show</a>.
newtype DodgyEq a
DodgyEq :: a -> DodgyEq a
[unDodgyEq] :: DodgyEq a -> a

-- | Setup logging before running the specs.
logSetup :: HasCallStack => SpecWith a -> SpecWith a

-- | Get log levels from environment variables and set up formatters.
specLogSetup :: IO ()

-- | Like <a>specLogSetup</a>, but with a default minimum priority.
specLogSetupPrio :: Priority -> IO ()

-- | Log a test message.
specLog :: MonadIO m => String -> m ()

-- | Log a test message at the given level.
specLogAt :: MonadIO m => Priority -> String -> m ()

-- | Find out the configured log level for specs.
getSpecLogPriority :: MonadIO m => m Priority
data Priority
DEBUG :: Priority
INFO :: Priority
NOTICE :: Priority
WARNING :: Priority
ERROR :: Priority
CRITICAL :: Priority
ALERT :: Priority
EMERGENCY :: Priority
instance GHC.Classes.Eq (System.Taffybar.Test.UtilSpec.DodgyEq a)
instance GHC.Internal.Show.Show (System.Taffybar.Test.UtilSpec.DodgyEq a)

module System.Taffybar.Test.DBusSpec
spec :: Spec

-- | Same as <a>withTestDBusInDir</a>, except that it creates and removes
--   the temporary directory for you.
withTestDBus :: IO a -> IO a

-- | Uses <a>withDBusDaemon_</a> to provide both a private session bus and
--   a private system bus while the given action is running.
--   
--   The <tt>DBUS_SESSION_BUS_ADDRESS</tt> and
--   <tt>DBUS_SYSTEM_BUS_ADDRESS</tt> environment variables will be set to
--   point to socket files within the given directory.
--   
--   Files in the directory will be left behind after this function
--   returns.
--   
--   <b>Note</b>: Environment variables are global to the process, so be
--   careful using this with <a>parallel</a> unit tests.
withTestDBusInDir :: FilePath -> IO a -> IO a
data Bus
Session :: Bus
System :: Bus

-- | Start a D-Bus daemon of the given <a>Bus</a> type, and set the
--   corresponding environment variable while running the given action.
--   
--   <b>Note</b>: Environment variables are global to the process, so be
--   careful using this with <a>parallel</a> unit tests. A safer option
--   could be <a>withConnectDBusDaemon'</a> and <tt>setBusEnv</tt>.
withDBusDaemon_ :: Bus -> FilePath -> IO a -> IO a
withConnectDBusDaemon :: Bus -> FilePath -> (Client -> IO a) -> IO a

-- | Same as <a>withDBusDaemon</a>, but it also provides a <a>Client</a>
--   connection.
withConnectDBusDaemon' :: Bus -> FilePath -> (Address -> Client -> IO a) -> IO a

-- | Adjust a <a>ProcessConfig</a> so that the child process will use the
--   given D-Bus address.
setDBusEnv :: Bus -> Address -> ProcessConfig i o e -> ProcessConfig i o e

-- | Set the <tt>DBUS_SESSION_BUS_ADDRESS</tt> or
--   <tt>DBUS_SYSTEM_BUS_ADDRESS</tt> environment variable according to the
--   given bus and address.
--   
--   <b>Note 1</b>: Environment variables are global to the process, so be
--   careful using this with <a>parallel</a> unit tests.
--   
--   <b>Note 2</b>. Using a <tt>DBUS_SYSTEM_BUS_ADDRESS</tt> environment
--   variable to set a custom system bus address is supported by libdbus
--   (therefore python-dbus) and haskell-dbus, but not necessarily other
--   libraries or programs. Notably, systemd hardcodes the system bus
--   address.
withBusEnv :: Bus -> Address -> IO a -> IO a

-- | Starts up <a><tt>python-dbusmock</tt></a>. The given action will be
--   run once the mock is ready.
withPythonDBusMock :: Bus -> (Address, Client) -> BusName -> ObjectPath -> InterfaceName -> IO a -> IO a
withTaffyMocks :: IO a -> IO a
withMatch :: MonadUnliftIO m => Client -> MatchRule -> (Signal -> m ()) -> m a -> m a
withClient :: Address -> (Client -> IO a) -> IO a
instance GHC.Internal.Enum.Enum System.Taffybar.Test.DBusSpec.Bus
instance GHC.Classes.Eq System.Taffybar.Test.DBusSpec.Bus
instance GHC.Internal.Read.Read System.Taffybar.Test.DBusSpec.Bus
instance GHC.Internal.Show.Show System.Taffybar.Test.DBusSpec.Bus

module System.Taffybar.Test.XvfbSpec

-- | Test the test util functions.
spec :: Spec
withXvfb :: (DisplayName -> IO a) -> IO a
withXdummy :: (DisplayName -> IO a) -> IO a

-- | Produce a <tt>-display</tt> command-line option, supported by many X11
--   programs.
displayArg :: DisplayName -> [String]
displayEnv :: DisplayName -> [(String, String)]

-- | Using the given <a>DisplayName</a>, run an action with the
--   <tt>DISPLAY</tt> environment variable set.
--   
--   NB. Don't run tests in parallel if using this. Environment variables
--   are process-global.
setDefaultDisplay_ :: DisplayName -> IO a -> IO a

-- | Same as <a>setDefaultDisplay_</a>, except the <a>DisplayName</a>
--   parameter is passed through to the action.
setDefaultDisplay :: DisplayName -> (DisplayName -> IO a) -> IO a
withRandrSetup :: DisplayName -> RRSetup -> IO a -> IO a
randrSetup :: DisplayName -> RRSetup -> IO ()
randrTeardown :: DisplayName -> RRSetup -> IO ()
data RRSetup
RRSetup :: [RROutput] -> Maybe (ListIndex RROutput) -> [RRMode] -> RRSetup
[outputs] :: RRSetup -> [RROutput]
[primary] :: RRSetup -> Maybe (ListIndex RROutput)
[newModes] :: RRSetup -> [RRMode]
data RROutput
RROutput :: Maybe RRExistingMode -> RROutputSettings -> RRPosition -> RROutput
[mode] :: RROutput -> Maybe RRExistingMode
[settings] :: RROutput -> RROutputSettings
[position] :: RROutput -> RRPosition
data RROutputSettings
RROutputSettings :: Bool -> RRRotation -> RROutputSettings
[disabled] :: RROutputSettings -> Bool
[rotate] :: RROutputSettings -> RRRotation

-- | This is an index into <a>modeLines</a>.
newtype RRExistingMode
RRExistingMode :: ListIndex RRMode -> RRExistingMode
[unRRExistingMode] :: RRExistingMode -> ListIndex RRMode
data RRMode
RRMode :: RRModeName -> RRModeLine -> RRMode
[name] :: RRMode -> RRModeName
[modeLine] :: RRMode -> RRModeLine
newtype RRModeName
RRModeName :: String -> RRModeName
[unRRModeName] :: RRModeName -> String
newtype RRModeLine
RRModeLine :: String -> RRModeLine
[unRRModeLine] :: RRModeLine -> String
data RRPosition
SameAs :: RRPosition
RightOf :: RRPosition
LeftOf :: RRPosition
Below :: RRPosition
Above :: RRPosition
data RRRotation
Unrotated :: RRRotation
RotateLeft :: RRRotation
Inverted :: RRRotation
RotateRight :: RRRotation

-- | Adds a guiding phantom type annotation for indices into lists. fixme:
--   zipper rather than indices
newtype ListIndex a
ListIndex :: Int -> ListIndex a
[unListIndex] :: ListIndex a -> Int
withXTerm :: (DisplayName -> IO a) -> DisplayName -> IO a
newtype XPropName
XPropName :: String -> XPropName
[unXPropName] :: XPropName -> String

-- | Construct a valid <a>XPropName</a> from a <a>String</a>. Any names
--   which cause problems when parsing <tt>xprop</tt> output are not
--   allowed.
xpropName :: String -> Maybe XPropName
newtype XPropValue
XPropValue :: String -> XPropValue
[unXPropValue] :: XPropValue -> String

-- | Construct a valid <a>XPropValue</a> from a <a>String</a>. Any values
--   which cause problems when parsing <tt>xprop</tt> output are not
--   allowed.
xpropValue :: String -> Maybe XPropValue
xpropGet :: (HasCallStack, MonadIO m) => DisplayName -> XPropName -> m [XPropValue]
xpropSet :: MonadIO m => DisplayName -> XPropName -> XPropValue -> m ()
xpropRemove :: MonadIO m => DisplayName -> XPropName -> m ()
xpropList :: MonadIO m => DisplayName -> m ()
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RRExistingMode
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RROutput
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RROutputSettings
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RRPosition
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RRRotation
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.RRSetup
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.XPropName
instance Test.QuickCheck.Arbitrary.Arbitrary System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Enum.Bounded System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Internal.Enum.Bounded System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Internal.Enum.Bounded System.Taffybar.Test.XvfbSpec.RRRotation
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RRExistingMode
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RROutput
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RROutputSettings
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RRPosition
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RRRotation
instance Data.Default.Internal.Default System.Taffybar.Test.XvfbSpec.RRSetup
instance GHC.Internal.Enum.Enum (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Enum.Enum System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Internal.Enum.Enum System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Internal.Enum.Enum System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Classes.Eq (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRMode
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRModeLine
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRModeName
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RROutput
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RROutputSettings
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.RRSetup
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.XPropName
instance GHC.Classes.Eq System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Generics.Generic (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRMode
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRModeLine
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRModeName
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RROutput
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RROutputSettings
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.RRSetup
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.XPropName
instance GHC.Internal.Generics.Generic System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Real.Integral (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Data.String.IsString System.Taffybar.Test.XvfbSpec.RRMode
instance GHC.Internal.Data.String.IsString System.Taffybar.Test.XvfbSpec.RRModeLine
instance GHC.Internal.Data.String.IsString System.Taffybar.Test.XvfbSpec.RRModeName
instance GHC.Internal.Base.Monoid System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Num.Num (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Classes.Ord (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Classes.Ord System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Classes.Ord System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Classes.Ord System.Taffybar.Test.XvfbSpec.XPropName
instance GHC.Classes.Ord System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Read.Read (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRMode
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRModeLine
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRModeName
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RROutput
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RROutputSettings
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.RRSetup
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.XPropName
instance GHC.Internal.Read.Read System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Real.Real (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Base.Semigroup System.Taffybar.Test.XvfbSpec.XPropValue
instance GHC.Internal.Show.Show (System.Taffybar.Test.XvfbSpec.ListIndex a)
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRExistingMode
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRMode
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRModeLine
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRModeName
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RROutput
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RROutputSettings
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRPosition
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRRotation
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.RRSetup
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.XPropName
instance GHC.Internal.Show.Show System.Taffybar.Test.XvfbSpec.XPropValue

module TestLibSpec
main :: IO ()
spec :: Spec
