Skip to content

Commit 3e8aa5b

Browse files
committed
Test nqp::readlink.
1 parent 75bd5c2 commit 3e8aa5b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

t/nqp/19-file-ops.t

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# Test nqp::op file operations.
44

5-
plan(88);
5+
plan(89);
66

77
ok( nqp::stat('CREDITS', nqp::const::STAT_EXISTS) == 1, 'nqp::stat exists');
88
ok( nqp::stat('AARDVARKS', nqp::const::STAT_EXISTS) == 0, 'nqp::stat not exists');
@@ -235,14 +235,15 @@ nqp::unlink($tmp-file);
235235
my $is-windows := $output ne "%NQP_SHELL_TEST_ENV_VAR%\n";
236236

237237
if $is-windows {
238-
skip("symlink not tested on Windows", 5);
238+
skip("symlink not tested on Windows", 6);
239239
}
240240
else {
241241
nqp::unlink($test-file ~ '-symlink') if nqp::stat($test-file ~ '-symlink', nqp::const::STAT_EXISTS);
242242
$fh := nqp::open($test-file, 'w');
243243
nqp::printfh($fh, 'Hello');
244244
nqp::closefh($fh);
245245
nqp::symlink($test-file, $test-file ~ '-symlink');
246+
ok(nqp::readlink($test-file ~ '-symlink') eq $test-file, 'nqp::readlink');
246247
ok(nqp::stat($test-file ~ '-symlink', nqp::const::STAT_EXISTS), 'the symbolic link should exist');
247248
ok(nqp::lstat($test-file ~ '-symlink', nqp::const::STAT_EXISTS), 'the symbolic link should exist');
248249
if nqp::getcomp('nqp').backend.name eq 'parrot' {

0 commit comments

Comments
 (0)