Branch Coverage

File:lib/CheckSpelling/Apply.pm
Coverage:51.7%

line%coveragebranch
36100TFif ($^O eq "MSWin32")
43100TFif -x $f
50100TFif check_exists_command($command)
63100TFif defined $token and $token ne ""
65100TFif defined $token and $token ne ""
7550TFunless defined $flags
96100TFif /^\s*(?:#.*)/
12350TF$output_joined ne '' ? :
13750TFif ($? == -1)
14150TFif ($? & 127)
1420TF$? & 128 ? :
14650TFif $? == 0
16350TFif ("$0" eq "-")
17550TFif ($? == 0)
17650TFif (compare_files($filename, $0))
18550TFif ($gh_err_text =~ /error connecting to / and $gh_err_text =~ /check your internet connection/)
189100TFif ($gh_err_text =~ /proxyconnect tcp:.*connect: connection refused/)
192100TFif (defined $ENV{$proxy})
199100TFif ($gh_err_text =~ /dial unix .*: connect: .*/)
21050TFif $exit_code == 0
21850TFif $gh_auth_status == 0
223100TFif (defined $ENV{$variable})
22750TFif ($gh_auth_status == 0)
24050TFunless (gh_is_happy($program))
24250TFdefined $ENV{'CI'} && $ENV{'CI'} ? :
26550TFunless $spell_check_this_config =~ /\{.*\}/s
26750TFunless eval {         do {         %config = %{decode_json($spell_check_this_config);} } }
27950TFif ($?)
29650TFunless ($should_exclude_patterns =~ /\w/)
29850TFunless $should_exclude_patterns =~ /\w/
30350TFif (-f $excludes) { }
30750TFunless /./
31550TFunless $pattern =~ /./
32150TFif $need_to_add_excludes
32750TFunless @stale
33050TFunless -f $_
33350TFunless (@expect_files)
342100TFif /^(?:$re)(?:(?:\r|\n)*$|[# ].*)/
35650TFunless @add
36050TFif (-s $new_expect_file)
37250TFif $word =~ /\S/
39150TFif defined $gh_token
399100TFunless ($curl_result == 0)
40050TFif ($curl_stdout eq "")
42550TFif ($count == 0)
445100TFif (defined $page)
44850TFif (defined $id_1 and defined $id_2)
44950TFif ($id_2 > $id_1)
45750TFif (defined $download)
469100TFif (defined $download)
48050TFif defined $gh_token
48850TFif ($curl_result != 0)
48950TFif ($curl_stdout eq "")
51750TFif ($suffix)
52850TFunless $ret >> 8
531100TFif ($gh_err_text =~ /no valid artifacts found to download|"Artifact has expired"/)
53850TFif ($expired_json ne "")
54150TFunless eval {         do {         $expired = decode_json($expired_json) } }
54250TFif ($expired)
55050TFif ($gh_err_text =~ /no artifact matches any of the names or patterns provided/)
5530TFif ($github_server_url) { }
56250TFif ($gh_err_text =~ /HTTP 404: Not Found|"status":"404"/)
5660TFif ($gh_err_text =~ /HTTP 403: API rate limit exceeded for .*?./) { }
0TFelsif ($gh_err_text =~ m[dial tcp \S+:\d+: i/o timeout$]) { }
5680TFif ($retries_remaining <= 0)
5770TFif $gh_err_text =~ /\brequest ID\s+(\S+)/
5780TFif $gh_err_text =~ /\btimestamp\s+(.*? UTC)/
5830TFunless ($has_gh_token)
5850TFif defined $gh_token
5910TFif ($curl_stdout =~ m[^HTTP/\S+\s+200]) { }
0TFelsif ($curl_stdout =~ m[^HTTP/\S+\s+403]) { }
5920TFif ($curl_stdout =~ /^x-ratelimit-remaining:\s+(\d+)$/m) { }
5940TFif $ratelimit_remaining > 10
6020TFif ($curl_stdout =~ /^retry-after:\s+(\d+)/m) { }
6090TFif $curl_stdout =~ m[^(HTTP/\S+)]
62050TFif $artifact =~ /'/
62250TFunless ($apply =~ /\{.*\}/s)
63250TFunless eval {         do {         $config_ref = decode_json($apply) } }
63750TFunless $git_repo_root =~ /\w/
653100TFif ($line =~ /\s+artifact\.zip$/)
657100TFif ($line =~ /\s+1 file$/)
66150TFif $only_file
66550TFif ($has_artifact and $only_file) { }
69150TFunless defined $first
695100TFif (-s $first) { }
69950TFif ($first =~ m[^\s*https://.*/([^/]+/[^/]+)/actions/runs/(\d+)(?:/attempts/\d+|)(?:#(\S+)|)\s*$]) { }
70450TFunless defined $repo and defined $run