6 plan skip_all => 'set TEST_STRESS to enable this test'
7 unless $ENV{TEST_STRESS};
11 use lib "$FindBin::Bin/lib";
12 use Catalyst::Test 'TestApp';
14 our ( $iters, $tests );
17 use JSON::MaybeXS qw(decode_json);
20 open my $fh, '<:raw', "$FindBin::Bin/optional_stress.json" or die "$!";
25 $iters = $ENV{TEST_STRESS} || 10;
26 $tests = decode_json($test_data);
29 map { $total_tests += scalar @{ $tests->{$_} } } keys %{$tests};
30 plan tests => $iters * $total_tests;
38 foreach my $test_group ( keys %{$tests} ) {
39 foreach my $test ( @{ $tests->{$test_group} } ) {
40 ok( request($test), $test_group . ' - ' . $test );