Skip to content

Commit ee57fd9

Browse files
committed
Correct a test to also work on Windows.
1 parent 2fda98b commit ee57fd9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

t/nqp/19-file-ops.t

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ my $credits := nqp::open('CREDITS', 'r');
1717
ok( $credits, 'nqp::open for read');
1818
ok( nqp::tellfh($credits) == 0, 'nqp::tellfh start of file');
1919
my $line := nqp::readlinefh($credits);
20-
ok( nqp::chars($line) == 5, 'nqp::readlinefh line to read'); # =pod\n
21-
ok( nqp::tellfh($credits) == 5, 'nqp::tellfh line two');
20+
ok( nqp::chars($line) == 5 || nqp::chars($line) == 6, 'nqp::readlinefh line to read'); # =pod\r?\n
21+
ok( nqp::tellfh($credits) == 5 || nqp::tellfh($credits) == 6, 'nqp::tellfh line two');
2222
my $rest := nqp::readallfh($credits);
2323
ok( nqp::chars($rest) > 100, 'nqp::readallfh lines to read');
2424
ok( nqp::tellfh($credits) == nqp::chars($line) + nqp::chars($rest), 'nqp::tellfh end of file');

0 commit comments

Comments
 (0)