Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

I guess people like tests or something

  • Loading branch information...
commit 4fcc2bd239509d87106ca824e6cfed403099dc9a 1 parent 99be235
@jamesgolick jamesgolick authored
Showing with 8 additions and 0 deletions.
  1. +8 −0 test/poolboy_tests.erl
View
8 test/poolboy_tests.erl
@@ -50,6 +50,9 @@ pool_test_() ->
},
{<<"Worker checked-in after an exception in a transaction">>,
fun checkin_after_exception_in_transaction/0
+ },
+ {<<"Pool returns status">>,
+ fun pool_returns_status/0
}
]
}.
@@ -363,6 +366,11 @@ checkin_after_exception_in_transaction() ->
?assertEqual(2, length(?sync(Pool, get_avail_workers))),
ok = ?sync(Pool, stop).
+pool_returns_status() ->
+ {ok, Pool} = new_pool(2, 0),
+ ?assertEqual({ready, 2, 0, 0}, poolboy:status(Pool)),
+ ok = ?sync(Pool, stop).
+
new_pool(Size, MaxOverflow) ->
poolboy:start_link([{name, {local, poolboy_test}},
{worker_module, poolboy_test_worker},
Please sign in to comment.
Something went wrong with that request. Please try again.