I'm trying to use it with tasty-wai: https://hackage.haskell.org/package/tasty-wai-0.1.1.0/docs/Test-Tasty-Wai.html
I opened a raw connection in my tests main, passed it to my API tests as well as the my app :: SqlBackend -> Application, and used a runDB function to run the SQL bits in my tests. It worked fine when I had a single test, but once I added another test with another sql block, it gave me an error:
Exception: SQLite3 returned ErrorError while attempting to perform step: cannot start a transaction within a transaction
Has anyone used the
Network.Wai.Test
module fromwai-extra
along with Persistent to test their handlers?I'm trying to use it with
tasty-wai
: https://hackage.haskell.org/package/tasty-wai-0.1.1.0/docs/Test-Tasty-Wai.htmlI opened a raw connection in my tests
main
, passed it to my API tests as well as the myapp :: SqlBackend -> Application
, and used arunDB
function to run the SQL bits in my tests. It worked fine when I had a single test, but once I added another test with another sql block, it gave me an error:Urg, just had to switch the test-suite to single-threaded...