I cannot find a way in a test script of making the open call fail. I have tried Test::MockObject and subs and liberal use of "BEGIN". The method appears to be loaded from IO::File.sub { .... my $string = get_string(); local *STDIN; open(STDIN, '<', \$string) or die "could not open $string"; binmode STDIN; .... }
In reply to Making open fail by SilasTheMonk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |