Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macOS: t/Tools_File.t fails. #1288

Merged
merged 1 commit into from Dec 9, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 5 additions & 2 deletions t/Tools_File.t
Expand Up @@ -136,9 +136,12 @@ ok(-d "$dir/foo/bar", 'mkdir_all second element');
is(get_perms("$dir/foo"), "0777", "first element, expected mode");
is(get_perms("$dir/foo/bar"), "0777", "second element, expected mode");

utime 1234567890, 123456789, $file;
# Note: Some platforms (e.g. macOS with Perl < 5.32) miss or simply don't
# implement futimes system call so that calling utime() on filehandle may
# crash.
utime 1234567890, 123456789, $file->filename;
is(Sympa::Tools::File::get_mtime($file), 123456789);
utime 123456789, 1234567890, $file;
utime 123456789, 1234567890, $file->filename;
is(Sympa::Tools::File::get_mtime($file), 1234567890);
ok(Sympa::Tools::File::get_mtime("$dir/no-such-file") < -32768);
chmod 0333, $file;
Expand Down