Merge branch 'master' of git@github.com:msgpack/msgpack

This commit is contained in:
tokuhirom
2010-05-03 01:04:50 +09:00
4 changed files with 223 additions and 1 deletions

View File

@@ -0,0 +1,26 @@
use strict;
use warnings;
use Data::MessagePack;
use Test::More;
my $input = [(undef)x16];
my $packed = Data::MessagePack->pack($input);
is_deeply(Data::MessagePack->unpack($packed), $input);
{
my $up = Data::MessagePack::Unpacker->new();
$up->execute($packed, 0);
ok $up->is_finished;
is_deeply $up->data, $input;
}
{
my $up = Data::MessagePack::Unpacker->new();
is $up->execute(substr($packed, 0, 3), 0), 3;
$up->execute($packed, 3);
ok $up->is_finished;
is_deeply $up->data, $input;
}
done_testing;