libcryptx-perl/t/mbi_ltm_storable.t

20 lines
389 B
Perl
Raw Permalink Normal View History

2018-03-22 15:51:09 +01:00
use strict;
use warnings;
use Test::More;
BEGIN {
plan skip_all => "requires Storable 2.0+" unless eval { require Storable && eval($Storable::VERSION) >= 2.0 };
plan tests => 1;
}
use Math::BigInt::LTM;
use Storable qw(freeze thaw);
my $num = Math::BigInt::LTM->_new(42);
my $serialised = freeze $num;
my $cloned = thaw $serialised;
ok(!Math::BigInt::LTM->_acmp($cloned, $num));