Move Locale::Codes from ext/ to cpan/
[p5sagit/p5-mst-13.2.git] / cpan / Math-BigInt / t / use_lib4.t
1 #!/usr/bin/perl -w
2
3 # see if using Math::BigInt and Math::BigFloat works together nicely.
4 # all use_lib*.t should be equivalent, except this, since the later overrides
5 # the former lib statement
6
7 use strict;
8 use Test;
9
10 BEGIN
11   {
12   $| = 1;
13   # to locate the testing files
14   my $location = $0; $location =~ s/use_lib4.t//i;
15   if ($ENV{PERL_CORE})
16     {
17     # testing with the core distribution
18     @INC = qw(../t/lib);
19     }
20   unshift @INC, qw(../lib);     # to locate the modules
21   if (-d 't')
22     {
23     chdir 't';
24     require File::Spec;
25     unshift @INC, File::Spec->catdir(File::Spec->updir, $location);
26     }
27   else
28     {
29     unshift @INC, $location;
30     }
31   print "# INC = @INC\n";
32
33   plan tests => 2;
34   } 
35
36 use Math::BigInt lib => 'BareCalc';
37 use Math::BigFloat lib => 'Calc';
38
39 ok (Math::BigInt->config()->{lib},'Math::BigInt::Calc');
40
41 ok (Math::BigFloat->new(123)->badd(123),246);
42