# test rounding, accuracy, precicion and fallback, round_mode and mixing
# of classes
use strict;
use Test;
{
$| = 1;
# to locate the testing files
{
}
else
{
}
if (-d 't')
{
chdir 't';
}
else
{
}
print "# INC = @INC\n";
+ 23; # own tests
}
$mbi = 'Math::BigInt';
$mbf = 'Math::BigFloat';
require 'mbimbf.inc';
# some tests that won't work with subclasses, since the things are only
# this)
my $x = eval '$mbi->round_mode("huhmbi");';
print "# Got '$@'\n" unless
$x = eval '$mbf->round_mode("huhmbf");';
print "# Got '$@'\n" unless
# old way (now with test for validity)
$x = eval '$Math::BigInt::rnd_mode = "huhmbi";';
print "# Got '$@'\n" unless
$x = eval '$Math::BigFloat::rnd_mode = "huhmbf";';
print "# Got '$@'\n" unless
# see if accessor also changes old variable
{
}
{
# global is still in effect for $x
# so the return value of that operation should
# be 42, not undef
}
# bug with flog(Math::BigFloat,Math::BigInt)
ok ($x,2);