diff --git a/glean/test/lib/Glean/Database/Test.hs b/glean/test/lib/Glean/Database/Test.hs index b8cc446cb..429120575 100644 --- a/glean/test/lib/Glean/Database/Test.hs +++ b/glean/test/lib/Glean/Database/Test.hs @@ -19,6 +19,8 @@ module Glean.Database.Test , setDBVersion , setCompactOnCompletion , setMaxSetSize + , enableTcDebug + , enableQueryDebug , withTestEnv , kickOffTestDB , waitUntilComplete @@ -105,6 +107,14 @@ setMaxSetSize i cfg = cfg { cfgServerConfig = cfgServerConfig cfg <&> \scfg -> scfg { ServerConfig.config_max_set_size_bytes = Just i } } +enableTcDebug :: Setting +enableTcDebug cfg = cfg + { cfgDebug = (cfgDebug cfg) { tcDebug = True } } + +enableQueryDebug :: Setting +enableQueryDebug cfg = cfg + { cfgDebug = (cfgDebug cfg) { queryDebug = True } } + withTestEnv :: [Setting] -> (Env -> IO a)