xref: /onnv-gate/usr/src/cmd/perl/5.8.4/distrib/t/TestInit.pm (revision 0:68f95e015346)
1*0Sstevel@tonic-gate# This is a replacement for the old BEGIN preamble which heads (or
2*0Sstevel@tonic-gate# should head) up every core test program to prepare it for running.
3*0Sstevel@tonic-gate# Now instead of:
4*0Sstevel@tonic-gate#
5*0Sstevel@tonic-gate# BEGIN {
6*0Sstevel@tonic-gate#   chdir 't' if -d 't';
7*0Sstevel@tonic-gate#   @INC = '../lib';
8*0Sstevel@tonic-gate# }
9*0Sstevel@tonic-gate#
10*0Sstevel@tonic-gate# t/TEST will use -MTestInit.  You may "use TestInit" in the test
11*0Sstevel@tonic-gate# programs but it is not required.
12*0Sstevel@tonic-gate#
13*0Sstevel@tonic-gate# P.S. This documentation is not in POD format in order to avoid
14*0Sstevel@tonic-gate# problems when there are fundamental bugs in perl.
15*0Sstevel@tonic-gate
16*0Sstevel@tonic-gatepackage TestInit;
17*0Sstevel@tonic-gate
18*0Sstevel@tonic-gate$VERSION = 1.01;
19*0Sstevel@tonic-gate
20*0Sstevel@tonic-gatechdir 't' if -d 't';
21*0Sstevel@tonic-gate@INC = '../lib';
22*0Sstevel@tonic-gate
23*0Sstevel@tonic-gate# Don't interfere with the taintedness of %ENV, this could perturbate tests
24*0Sstevel@tonic-gate$ENV{PERL_CORE} = 1 unless ${^TAINT};
25*0Sstevel@tonic-gate
26*0Sstevel@tonic-gate$0 =~ s/\.dp$//; # for the test.deparse make target
27*0Sstevel@tonic-gate1;
28*0Sstevel@tonic-gate
29