Commit | Line | Data |
e940ddbb |
1 | #!./perl -w |
2 | |
3 | BEGIN { |
4 | chdir 't' if -d 't'; |
5 | @INC = '../lib'; |
6 | } |
7 | |
e940ddbb |
8 | use Test::More tests => 8; |
444e39b5 |
9 | use Config; |
e940ddbb |
10 | |
11 | ok( binmode(STDERR), 'STDERR made binary' ); |
444e39b5 |
12 | if ($Config{useperlio}) { |
13 | ok( binmode(STDERR, ":unix"), ' with unix discipline' ); |
14 | } else { |
15 | ok(1, ' skip unix discipline for -Uuseperlio' ); |
16 | } |
e940ddbb |
17 | ok( binmode(STDERR, ":raw"), ' raw' ); |
18 | ok( binmode(STDERR, ":crlf"), ' and crlf' ); |
19 | |
20 | # If this one fails, we're in trouble. So we just bail out. |
21 | ok( binmode(STDOUT), 'STDOUT made binary' ) || exit(1); |
444e39b5 |
22 | if ($Config{useperlio}) { |
23 | ok( binmode(STDOUT, ":unix"), ' with unix discipline' ); |
24 | } else { |
25 | ok(1, ' skip unix discipline for -Uuseperlio' ); |
26 | } |
27 | ok( binmode(STDOUT, ":raw"), ' raw' ); |
28 | ok( binmode(STDOUT, ":crlf"), ' and crlf' ); |