X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=t%2Flive_component_controller_context_closure.t;h=72ddb157f34b0ac6949bbc124d9bc9812630fa31;hp=7e111f35199791d9eb132e0d16e75d1d1798b18a;hb=50b07d604b372d9487863120b9df9c813bbe7334;hpb=4a0dc2595b2ed1f6ab0e79ff4727eb9135be1665 diff --git a/t/live_component_controller_context_closure.t b/t/live_component_controller_context_closure.t index 7e111f3..72ddb15 100644 --- a/t/live_component_controller_context_closure.t +++ b/t/live_component_controller_context_closure.t @@ -7,7 +7,7 @@ BEGIN { plan skip_all => 'CatalystX::LeakChecker 0.05 required for this test'; } - plan tests => 4; + plan tests => 6; } use FindBin; @@ -20,6 +20,10 @@ use Catalyst::Test 'TestApp'; { my ($resp, $ctx) = ctx_request('/contextclosure/normal_closure'); ok($resp->is_success); + #is($ctx->count_leaks, 1); + # FIXME: find out why this changed from 1 to 2 after 52af51596d + # ^^ probably has something to do with env being in Engine and Request - JNAP + # ^^ I made the env in Engine a weak ref, should help until we can remove it is($ctx->count_leaks, 1); } @@ -28,3 +32,9 @@ use Catalyst::Test 'TestApp'; ok($resp->is_success); is($ctx->count_leaks, 0); } + +{ + my ($resp, $ctx) = ctx_request('/contextclosure/non_closure'); + ok($resp->is_success); + is($ctx->count_leaks, 0); +}