Branch Coverage

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

line%coveragebranch
5100TFif defined $exited
510TFif ($^O eq "MSWin32")
580TFif -x $f
650TFif check_exists_command($program)
78100TFif defined $token and $token ne ""
8050TFif defined $token and $token ne ""
880TFunless defined $flags
1090TFif /^\s*(?:#.*)/
136100TF$output_joined ne '' ? :
1500TFif ($? == -1)
1540TFif ($? & 127)
1550TF$? & 128 ? :
1590TFif $? == 0
1760TFif ("$0" eq "-")
1880TFif ($? == 0)
1890TFif (compare_files($filename, $0))
19850TFif ($gh_err_text =~ /error connecting to / and $gh_err_text =~ /check your internet connection/)
20250TFif ($gh_err_text =~ /proxyconnect tcp:.*connect: connection refused/)
2050TFif (defined $ENV{$proxy})
212100TFif ($gh_err_text =~ /dial unix .*: connect: .*/)
223100TFif $exit_code == 0
231100TFif $gh_auth_status == 0
236100TFif (defined $ENV{$variable})
24050TFif ($gh_auth_status == 0)
253100TFunless (gh_is_happy($program))
25550TFdefined $ENV{'CI'} && $ENV{'CI'} ? :
2610TFif $_[0]
2820TFunless $spell_check_this_config =~ /\{.*\}/s
2840TFunless eval {         do {         %config = %{decode_json($spell_check_this_config);} } }
2960TFif ($?)
3140TFunless ($should_exclude_patterns =~ /\w/)
3160TFunless $should_exclude_patterns =~ /\w/
3210TFif (-f $excludes) { }
3250TFunless /./
3330TFunless $pattern =~ /./
3390TFif $need_to_add_excludes
3450TFunless @stale
3490TFunless -f $_
3520TFunless (@expect_files)
3610TFif /^(?:$re)(?:(?:\r|\n)*$|[# ].*)/
3750TFunless @add
3800TFif (-s $new_expect_file)
3920TFif $word =~ /\S/
41150TFif defined $gh_token
419100TFunless ($curl_result == 0)
42050TFif ($curl_stdout eq "")
44550TFif ($count == 0)
465100TFif (defined $page)
46850TFif (defined $id_1 and defined $id_2)
46950TFif ($id_2 > $id_1)
477100TFif (defined $download)
489100TFif (defined $download)
50050TFif defined $gh_token
50850TFif ($curl_result != 0)
50950TFif ($curl_stdout eq "")
53750TFif ($suffix)
54850TFunless $ret >> 8
551100TFif ($gh_err_text =~ /no valid artifacts found to download|"Artifact has expired"/)
55850TFif ($expired_json ne "")
56150TFunless eval {         do {         $expired = decode_json($expired_json) } }
56250TFif ($expired)
57050TFif ($gh_err_text =~ /no artifact matches any of the names or patterns provided/)
5730TFif ($github_server_url) { }
58250TFif ($gh_err_text =~ /HTTP 404: Not Found|"status":"404"/)
5860TFif ($gh_err_text =~ /HTTP 403: API rate limit exceeded for .*?./) { }
0TFelsif ($gh_err_text =~ m[dial tcp \S+:\d+: i/o timeout$]) { }
5880TFif ($retries_remaining <= 0)
5970TFif $gh_err_text =~ /\brequest ID\s+(\S+)/
5980TFif $gh_err_text =~ /\btimestamp\s+(.*? UTC)/
6030TFunless ($has_gh_token)
6050TFif defined $gh_token
6110TFif ($curl_stdout =~ m[^HTTP/\S+\s+200]) { }
0TFelsif ($curl_stdout =~ m[^HTTP/\S+\s+403]) { }
6120TFif ($curl_stdout =~ /^x-ratelimit-remaining:\s+(\d+)$/m) { }
6140TFif $ratelimit_remaining > 10
6220TFif ($curl_stdout =~ /^retry-after:\s+(\d+)/m) { }
6290TFif $curl_stdout =~ m[^(HTTP/\S+)]
6390TFif $artifact =~ /'/
6420TFunless ($apply =~ /\{.*\}/s)
6520TFunless eval {         do {         $config_ref = decode_json($apply) } }
6570TFunless $git_repo_root =~ /\w/
6730TFif ($line =~ /\s+artifact\.zip$/)
6770TFif ($line =~ /\s+1 file$/)
6810TFif $only_file
6850TFif ($has_artifact and $only_file) { }
7110TFunless defined $first
7150TFif (-s $first) { }
7190TFif ($first =~ m[^\s*https://.*/([^/]+/[^/]+)/actions/runs/(\d+)(?:/attempts/\d+|)(?:#(\S+)|)\s*$]) { }
7240TFunless defined $repo and defined $run