File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ my $english_locale = (Win32::FormatMessage(1) eq "Incorrect function.\r\n");
18
18
# We may not always have an internet connection, so don't
19
19
# attempt remote connections unless the user has done
20
20
# set PERL_WIN32_INTERNET_OK=1
21
- plan tests => $ENV {PERL_WIN32_INTERNET_OK } ? 12 : 7;
21
+ plan tests => $ENV {PERL_WIN32_INTERNET_OK } ? 13 : 7;
22
22
23
23
# On Cygwin the test_harness will invoke additional Win32 APIs that
24
24
# will reset the Win32::GetLastError() value, so capture it immediately.
@@ -71,7 +71,15 @@ if ($ENV{PERL_WIN32_INTERNET_OK}) {
71
71
skip(" Cannot verify error on non-English locale setting" );
72
72
}
73
73
# Since all GitHub downloads use redirects, we can test that they work.
74
+ 1 while unlink $tmpfile ;
74
75
ok(Win32::HttpGetFile(' https://github.com/perl-libwin32/win32/archive/refs/tags/v0.57.zip' , $tmpfile ),
75
76
' 1' ,
76
77
" successfully downloaded a zipball via redirect" );
78
+
79
+ $sha = undef ;
80
+ $sha = Digest::SHA-> new(' sha1' );
81
+ $sha -> addfile($tmpfile , ' b' );
82
+ ok($sha -> hexdigest,
83
+ ' 9d282e2292e67fb2e25422dfb190474e30a38de3' ,
84
+ " downloaded GitHub zip archive has correct digest" );
77
85
}
You can’t perform that action at this time.
0 commit comments