Test-File-Contents

 view release on metacpan or  search on metacpan

lib/Test/File/Contents.pm  view on Meta::CPAN

        : $encoding =~ '^:' ? $encoding
        :                     ":encoding($encoding)";
    open my $fh, "<$layer", $file or return;
    return '' if eof $fh;
    # Don't use `local $/; return <$fh>;`, it does not work on Windows.
    # See https://rt.perl.org/Ticket/Display.html?id=127668 for details.
    return join '', <$fh>;
}

sub _resolve {
    $_[0] =~ m{/} ? File::Spec->catfile(split m{/}, shift) : shift;
}

1;

__END__

=pod

=head1 AUTHOR



( run in 0.451 second using v1.01-cache-2.11-cpan-5511b514fd6 )