my $TEST_MODE = 1; sub file_exists { my ($filename) = @_; if ($TEST_MODE) { return 1; } return (-f $filename); }