Commit | Line | Data |
729c079f |
1 | #!./perl |
2 | |
3 | BEGIN { |
4 | chdir 't' if -d 't'; |
5 | @INC = ('.', '../lib'); |
6 | } |
7 | |
8 | require 'test.pl'; |
9 | |
15547071 |
10 | plan (9); |
729c079f |
11 | |
12 | my $blank = ""; |
13 | eval {select undef, $blank, $blank, 0}; |
14 | is ($@, ""); |
15 | eval {select $blank, undef, $blank, 0}; |
16 | is ($@, ""); |
17 | eval {select $blank, $blank, undef, 0}; |
18 | is ($@, ""); |
19 | |
20 | eval {select "", $blank, $blank, 0}; |
15547071 |
21 | is ($@, ""); |
729c079f |
22 | eval {select $blank, "", $blank, 0}; |
15547071 |
23 | is ($@, ""); |
729c079f |
24 | eval {select $blank, $blank, "", 0}; |
15547071 |
25 | is ($@, ""); |
26 | |
27 | eval {select "a", $blank, $blank, 0}; |
28 | like ($@, qr/^Modification of a read-only value attempted/); |
29 | eval {select $blank, "a", $blank, 0}; |
30 | like ($@, qr/^Modification of a read-only value attempted/); |
31 | eval {select $blank, $blank, "a", 0}; |
729c079f |
32 | like ($@, qr/^Modification of a read-only value attempted/); |