mirror of
https://codeberg.org/h3xx/simplify_static_dir
synced 2024-08-14 23:57:24 +00:00
Use croak/carp instead of die/warn (PBP)
This commit is contained in:
parent
4e2e94881b
commit
3e96b9bc19
3 changed files with 8 additions and 5 deletions
|
@ -3,6 +3,7 @@ use strict;
|
|||
use warnings;
|
||||
|
||||
use Test::More 'no_plan';
|
||||
use Carp qw/ croak /;
|
||||
|
||||
use TestFunctions;
|
||||
|
||||
|
@ -20,7 +21,7 @@ sub put_file {
|
|||
my $bytes = 1048576; # 1 MB
|
||||
foreach my $file (@files) {
|
||||
open my $fh, '>', $file
|
||||
or die "Failed to open file $file for writing: $!";
|
||||
or croak("Failed to open file $file for writing: $!");
|
||||
for (my $bytes_written = 0; $bytes_written < $bytes; ++$bytes_written) {
|
||||
print $fh 'A';
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue