bigrat.t revision 7c478bd95313f5f23a4c958a745db2134aa03244
use strict;
use Test;
{
$| = 1;
chdir 't' if -d 't';
}
# testing of Math::BigRat
# shortcuts
my $cr = 'Math::BigRat';
my $mbi = 'Math::BigInt';
my $mbf = 'Math::BigFloat';
my ($x,$y,$z);
##############################################################################
# new and bnorm()
{
# input ala '1+1/3' isn't parsed ok yet
############################################################################
# other classes as input
}
# wrong inputs
# failed due to BigFlaot bug
##############################################################################
# mixed arguments
##############################################################################
$x -= '0.1';
ok ($x < $y,1);
'1732050807568877293527446341505872366943/'
.'2000000000000000000000000000000000000000');
##############################################################################
# bpow
# XXX todo:
#$x = $cr->new('2/3'); $z = $x->bpow('5/3'); ok ($x,'32/81 ???');
##############################################################################
# bfac
for (my $i = 0; $i < 8; $i++)
{
}
# test for $self->bnan() vs. $x->bnan();
##############################################################################
##############################################################################
##############################################################################
# bsstr
##############################################################################
# numify()
##############################################################################
# broot(), bmodpow() and bmodinv()
# square root with exact result
# log with exact result
ok ($x->copy()->blog(2), '8000563442710106079310294693803606983661/1000000000000000000000000000000000000000');
##############################################################################
# done
1;