diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2003-09-13 10:10:46 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-09-13 10:10:46 +0000 |
commit | 7e72d50951f9200af403999824e9d3fc17f03570 (patch) | |
tree | e09b646c1fae6da3afd4885f65ff388d0f6404d9 /t/io/open.t | |
parent | c2be40b189b2d5e759e6de4217ec02ed2234bc6c (diff) | |
download | perl-7e72d50951f9200af403999824e9d3fc17f03570.tar.gz |
Apparently at some point doing 3-arg open with
illegal mode like ">>>" had stopped croaking.
p4raw-id: //depot/perl@21206
Diffstat (limited to 't/io/open.t')
-rwxr-xr-x | t/io/open.t | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/t/io/open.t b/t/io/open.t index 87a9c5580b..b8020c24c3 100755 --- a/t/io/open.t +++ b/t/io/open.t @@ -12,7 +12,7 @@ use Config; $Is_VMS = $^O eq 'VMS'; $Is_MacOS = $^O eq 'MacOS'; -plan tests => 100; +plan tests => 102; my $Perl = which_perl(); @@ -279,3 +279,16 @@ SKIP: { like($@, qr/<\$fh3{...}> line 1\./, "autoviv fh lexical helem"); } +SKIP: { + skip("This test uses perlio", 1) unless $Config{useperlio}; + my $w; + use warnings 'layer'; + local $SIG{__WARN__} = sub { $w = shift }; + + eval { open(F, ">>>", "afile") }; + like($w, qr/perlio: invalid separator character '>' in layer spec/, + "bad open warning"); + like($@, qr/Unknown open\(\) mode '>>>'/, + "bad open failure"); +} + |