This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Add tests for new IO extension
[perl5.git] / t / lib / io_xs.t
1 #!./perl
2 $| = 1;
3
4 BEGIN {
5     chdir 't' if -d 't';
6     @INC = '../lib' if -d '../lib';
7     require Config; import Config;
8     if ($Config{'extensions'} !~ /\bIO\b/ && !($^O eq 'VMS')) {
9         print "1..0\n";
10         exit 0;
11     }
12 }
13
14 use IO::File;
15 use IO::Seekable;
16
17 print "1..2\n";
18 use IO::File;
19 $x = new_tmpfile IO::File or print "not ";
20 print "ok 1\n";
21 print $x "ok 2\n";
22 $x->seek(0,SEEK_SET);
23 print <$x>;