Branch Coverage

blib/lib/WebService/Redmine.pm
Criterion Covered Total %
branch 34 62 54.8


line true false branch
229 0 1 if (length $$self{'host'} and $$self{'host'} =~ m[^(https?)://]i) { }
233 0 1 unless $$self{'protocol'} =~ /^https?$/i
237 0 1 if (not length $$self{'key'} and length $$self{'user'})
239 0 0 if (length $$self{'pass'})
248 0 1 if (length $$self{'key'})
251 0 1 if (length $$self{'work_as'})
307 0 0 if $method eq 'DESTROY'
319 0 0 if ($$r{'method'} eq 'GET' and ref $$r{'query'} eq 'HASH')
328 0 0 if ($$r{'method'} ne 'GET' and defined $$r{'content'})
330 0 0 if ($@)
346 0 0 unless ($response->is_success)
355 0 0 if ($request->method eq 'PUT' or $request->method eq 'DELETE')
360 0 0 if ($@)
364 0 0 if ($$self{'expect_single_object'} and $$self{'no_wrapper_object'})
379 12 16 if (not $action or $action eq 'read')
382 1 27 unless ($objects)
400 13 14 if ($action eq 'get') { }
11 3 elsif ($action eq 'create' or $action eq 'update') { }
401 10 3 if (ref $args[-1] eq 'HASH')
407 4 7 if (ref $args[-1] ne 'ARRAY' and ref $args[-1] ne 'HASH')
424 9 20 if $object eq $category
431 15 5 if ($action ne 'create' or not $is_last_object)
434 2 13 if not defined $object_id or ref \$object_id ne 'SCALAR'
441 12 6 if $is_last_object
458 12 0 if (length $object)
459 7 5 if ($action eq 'get' or $action eq 'create')
462 0 12 if ($$self{'no_wrapper_object'})
463 0 0 if ($action eq 'create' or $action eq 'update')
512 20 9 if (not $category =~ /s$/ or $category =~ /us$/)
513 5 15 if ($object =~ /y$/) { }
0 15 elsif ($category =~ /us$/) { }