Use hasql-transaction

Also use hspec before-wrapper
This commit is contained in:
Joe Nelson
2016-02-21 18:05:25 -08:00
parent 30e5032ade
commit d5c1438c6e
7 changed files with 18 additions and 31 deletions
+2 -2
View File
@@ -27,9 +27,9 @@ main = do
result <- P.use pool $ getDbStructure "test"
let dbStructure = either (error.show) id result
withApp = ($ postgrest cfgDefault dbStructure pool)
withApp = return $ postgrest cfgDefault dbStructure pool
hspec . sequence_ . map (around withApp) $ specs
hspec . sequence_ . map (before withApp) $ specs
where
specs = map (uncurry describe) [