3 # Tests for Perl mad environment
10 require Config; import Config;
12 skip_all_without_config('mad');
18 my $tempdir = tempfile;
20 mkdir $tempdir, 0700 or die "Can't mkdir '$tempdir': $!";
21 unshift @INC, '../../lib';
33 delete local $ENV{$_} for keys %ENV;
34 my $fn = File::Spec->catfile(File::Spec->curdir(), "withoutT.xml");
35 $ENV{PERL_XMLDUMP} = $fn;
36 fresh_perl_is('print q/hello/', '', {}, 'mad without -T');
37 ok(-f $fn, "xml file created without -T as expected");
41 delete local $ENV{$_} for keys %ENV;
42 my $fn = File::Spec->catfile(File::Spec->curdir(), "withT.xml");
43 fresh_perl_is('print q/hello/', 'hello', { switches => [ "-T" ] },
45 ok(!-e $fn, "no xml file created with -T as expected");