in reply to Mocking files for reading

Just a thought: could you mock your files with "in-memory" files (perl >= 5.8) ?
my $str = ''; open my $fh, '+>', \$str or die $!; print {$fh} "$_\n" for qw( foo bar baz ); seek $fh, 0, SEEK_SET; print <$fh>;