Closed stavro closed 8 years ago
@fishcakez I dug in a bit to try and build a test, but I don't fully understand what's going on enough with the owner / ownership / pool exiting status during a checkout.
I can try to spend more time on it later, but I haven't been able to put together any meaningful test yet.
We need to create some tests where the check out times out. The easiest would be with nested runs:
DBConnection.run(pid, fn(_) ->
DBConnection.run(pid, fn(_) -> flunk("did not time out") end)
end)
Unfortunately time outs cause different errors depending on the pool. We would need to use tags and have one test for the sojourn pool with assertraise and one test for the other pools with `assert {:timeout, } = catch_exit ..`
I guess the best spot for this would be queue_test.exs.
Thank you! :heart:
I have added a test in https://github.com/fishcakez/db_connection/commit/1d764119530e350a30d82e0299a547ea7e0d56d9
When can we expect this to get into a tagged release?
@alakra I will aim to tag v1.0 earlier next week. If this is causing you issues I can create a 0.2 branch and cherrypick this/release new 0.2.* release.
I can wait for 1.0. Thanks for such a quick response!
On Fri, May 27, 2016 at 1:53 PM James Fish notifications@github.com wrote:
@alakra https://github.com/alakra I will aim to tag v1.0 earlier next week. If this is causing you issues I can create a 0.2 branch and cherrypick this/release new 0.2.* release.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/fishcakez/db_connection/pull/36#issuecomment-222238663, or mute the thread https://github.com/notifications/unsubscribe/AAAK95HuwHT9ubBaZiHnNqMWuX7SKASFks5qF0ufgaJpZM4IRXpR .
- Angelo Lakra
The fix is perfect but could we get a test please?