Is there a way to make C<require> or C<use> fail without manipulating @INC or hiding the physical file? Or more generally, how do you test all branches of constructs like:

if ( eval {require Foo} ) {
  useFoo();
} elsif ( eval {require Alternate} ) {
  useAlternate();
} else {
  fake_it();
}


Thanks,
Randy.

Reply via email to